DRY
This commit is contained in:
parent
81e1b84129
commit
fcffcd35af
1 changed files with 6 additions and 10 deletions
|
@ -58,18 +58,14 @@
|
||||||
var seconds = this.model.get('expirationTimerUpdate').expireTimer;
|
var seconds = this.model.get('expirationTimerUpdate').expireTimer;
|
||||||
var timerMessage;
|
var timerMessage;
|
||||||
if (this.conversation.id === textsecure.storage.user.getNumber()) {
|
if (this.conversation.id === textsecure.storage.user.getNumber()) {
|
||||||
timerMessage = {
|
timerMessage = i18n('youChangedTheTimer',
|
||||||
content: i18n('youChangedTheTimer',
|
Whisper.ExpirationTimerOptions.getName(seconds));
|
||||||
Whisper.ExpirationTimerOptions.getName(seconds))
|
|
||||||
};
|
|
||||||
} else {
|
} else {
|
||||||
timerMessage = {
|
timerMessage = i18n('theyChangedTheTimer', [
|
||||||
content: i18n('theyChangedTheTimer', [
|
this.conversation.getTitle(),
|
||||||
this.conversation.getTitle(),
|
Whisper.ExpirationTimerOptions.getName(seconds)]);
|
||||||
Whisper.ExpirationTimerOptions.getName(seconds)])
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
return timerMessage;
|
return { content: timerMessage };
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue