Fix getUnread query
Booleans are not valid keys in indexeddb. https://www.w3.org/TR/IndexedDB/#dfn-valid-key // FREEBIE
This commit is contained in:
parent
aac9f3ec4c
commit
c4a88dd651
2 changed files with 4 additions and 4 deletions
|
@ -176,7 +176,7 @@
|
|||
received_at : now,
|
||||
conversationId : source,
|
||||
type : 'incoming',
|
||||
unread : true
|
||||
unread : 1
|
||||
});
|
||||
|
||||
return message;
|
||||
|
|
|
@ -56,9 +56,9 @@
|
|||
return unreadMessages.fetch({
|
||||
index: {
|
||||
// 'unread' index
|
||||
name: 'unread',
|
||||
lower: [conversationId, true],
|
||||
upper: [conversationId, true]
|
||||
name : 'unread',
|
||||
lower : [conversationId],
|
||||
upper : [conversationId, Number.MAX_VALUE],
|
||||
}
|
||||
}).always(function() {
|
||||
resolve(unreadMessages);
|
||||
|
|
Loading…
Reference in a new issue