You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
session-desktop/js
Scott Nonnenberg 4cba16cb61 Fetch all conversations on startup of app, not on inbox load (#1437)
* Fetch all conversations on startup of app, not on inbox load

A recent change to fetch conversations less didn't take into account all
that can happen in the app without the inbox loaded. That only happens
when the window is shown, and messages can come in with the app in the
background. In that case, the conversation wouldn't have been loaded
from the database, but would be saved to the database anyway, losing
data.

This change fetches all conversations as soon as the the data store is
ready for a fetch. It also introduces failsafe throws to ensure that
synchronous ConversationController accesses don't happen until the
initial fetch is complete. A new getUnsafe() method was required to
account for some of the model setup that happens during that initial
conversation fetch.

Fixes #1428

FREEBIE

* Fix tests: ConversationController.load() required before get()

FREEBIE
8 years ago
..
models Fetch all conversations on startup of app, not on inbox load (#1437) 8 years ago
views Fetch conversations once, clean up ConversationController API (#1420) 8 years ago
Mp3LameEncoder.min.js Add voice notes 9 years ago
WebAudioRecorderMp3.js Add voice notes 9 years ago
background.js Fetch all conversations on startup of app, not on inbox load (#1437) 8 years ago
backup.js Export: Properly generate directory names for nameless groups (#1421) 8 years ago
chromium.js Move clear/drawAttention logging up a level to reduce verbosity 8 years ago
components.js Introduce new filesize dependency 8 years ago
conversation_controller.js Fetch all conversations on startup of app, not on inbox load (#1437) 8 years ago
conversation_panel.js
database.js Cache messages on receipt, remove from cache when processed 8 years ago
debugLog.js Increase log length to 5000, since we're logging so much now 8 years ago
delivery_receipts.js Additional logging when we get delivery receipt for unknown msg 8 years ago
emoji_util.js Bulletproof getCountOfAllMatches against non-global regex input 8 years ago
expire.js Add build support for expiring old releases 9 years ago
expiring_messages.js Fetch all conversations on startup of app, not on inbox load (#1437) 8 years ago
index.js Use appendChild instead of append 8 years ago
keychange_listener.js Fetch conversations once, clean up ConversationController API (#1420) 8 years ago
libphonenumber-util.js
libsignal-protocol-worker.js Update libsignal-protocol v1.0.0 9 years ago
libtextsecure.js Fix race handling contact sync with verified info (#1419) 8 years ago
notifications.js Fetch conversations once, clean up ConversationController API (#1420) 8 years ago
options.js Move Whisper.events out of views and tests 8 years ago
panel_controller.js Move clear/drawAttention logging up a level to reduce verbosity 8 years ago
read_receipts.js Read/Delivery Receipts: Wait for resolution in main queue 8 years ago
register.js Fix minor style errors 9 years ago
registration.js Refactor registration event 9 years ago
reliable_trigger.js Apply reliable trigger to Backbone.Collection as well 8 years ago
rotate_signed_prekey_listener.js Remove some global refs to window.events 8 years ago
signal_protocol_store.js isUntrusted: Return false if firstUse is true 8 years ago
storage.js Log on failure to fetch storage 9 years ago
wall_clock_listener.js Remove some global refs to window.events 8 years ago