Show members: Pull conversation from group table
This commit is contained in:
parent
12739ac82d
commit
462fa712bc
4 changed files with 27 additions and 14 deletions
|
@ -74,6 +74,17 @@
|
|||
this.trigger('messageError', message, errors);
|
||||
},
|
||||
|
||||
getContactCollection() {
|
||||
const collection = new Backbone.Collection();
|
||||
const collator = new Intl.Collator();
|
||||
collection.comparator = (left, right) => {
|
||||
const leftLower = left.getTitle().toLowerCase();
|
||||
const rightLower = right.getTitle().toLowerCase();
|
||||
return collator.compare(leftLower, rightLower);
|
||||
};
|
||||
return collection;
|
||||
},
|
||||
|
||||
initialize() {
|
||||
this.ourNumber = textsecure.storage.user.getNumber();
|
||||
this.verifiedEnum = textsecure.storage.protocol.VerifiedStatus;
|
||||
|
@ -82,13 +93,7 @@
|
|||
// our first save to the database. Or first fetch from the database.
|
||||
this.initialPromise = Promise.resolve();
|
||||
|
||||
this.contactCollection = new Backbone.Collection();
|
||||
const collator = new Intl.Collator();
|
||||
this.contactCollection.comparator = (left, right) => {
|
||||
const leftLower = left.getTitle().toLowerCase();
|
||||
const rightLower = right.getTitle().toLowerCase();
|
||||
return collator.compare(leftLower, rightLower);
|
||||
};
|
||||
this.contactCollection = this.getContactCollection();
|
||||
this.messageCollection = new Whisper.MessageCollection([], {
|
||||
conversation: this,
|
||||
});
|
||||
|
|
|
@ -633,7 +633,7 @@
|
|||
// back to the conversation's current recipients
|
||||
const phoneNumbers = this.isIncoming()
|
||||
? [this.get('source')]
|
||||
: this.get('recipients') || this.conversation.getRecipients();
|
||||
: this.get('sent_to') || this.conversation.getRecipients();
|
||||
|
||||
// This will make the error message for outgoing key errors a bit nicer
|
||||
const allErrors = (this.get('errors') || []).map(error => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue