Commit graph

16 commits

Author SHA1 Message Date
Michael Kirk dd1aa26827 Prevent destroying user database after resetting device.
// FREEBIE
2017-01-23 17:15:40 -05:00
Matthew Chen c5cf79c399 Detect, warn about and try to recover from database password retrieval and database load errors.
// FREEBIE
2017-01-10 16:55:54 -05:00
Michael Kirk 5ccbd4ca6d Bail if we can't build a database.
* Something is irrecoverably wrong at this point.
* Constantize error names

// FREEBIE
2016-12-16 14:49:39 -06:00
Sam Vevang f8bb46c46c check for errors in the keychain password retrieval
// FREEBIE
2016-12-16 14:32:30 -06:00
Michael Kirk 70e536ca8f Privacy preferences for blocking identity change
// FREEBIE
2016-11-10 16:28:36 -05:00
Michael Kirk 40cdc7f224 disappearing messages
* Support for disappearing messages
* update inbox thread preview when receiving message

// FREEBIE
2016-10-11 09:24:40 -04:00
Michael Kirk f256617636 If we can't find a class definition, don't explode, just log.
If we have a serialized object in our data store that wasn't properly
removed, we can be faced with an exception when enumerating objects in
the database, e.g. when we add a new Yap Index.

// FREEBIE
2016-09-28 12:07:22 -04:00
Michael Kirk 5b06b4351f Fix timeout on launch for some users (#36)
This would especially affect users with large databases on older
devices.

Some of these database extensions aren't strictly necessary to launch
the app. Theoretically we could see weird read receipt behavior for
the initial 10-30 seconds after the app is launched for first time.

// FREEBIE
2016-09-28 00:07:42 -04:00
Michael Kirk 1098bc203e Fix crash on boot (#33)
A botched migration 6 months ago left some lingering TSRecipients
serialized in our data store, laying in wait to explode the next time we
enumerate every object in the database (e.g. when we add an index).

// FREEBIE
2016-09-26 21:23:06 -04:00
Michael Kirk 800e2a9541 Log exception rather than crash upon failed deserialization
while populating secondary indexes

// FREEBIE
2016-09-13 15:17:57 -04:00
Michael Kirk 0933b92128 Fix race condition with read receipts before incoming message
// FREEBIE
2016-09-09 15:11:41 -04:00
Michael Kirk c8a5f50763 Fixup DevicesManager
* By providing a view extension for secondary devices we can use that in
  a view mapping to power our devices view controller, and avoid any race
  conditions with uncommitted transactions.

* Fix crash when you're not in your own contacts

* New device appears on top

* Don't show "edit" button unless there are devices, or rather, the helpers to do so.

* Fix glitchy refresh

  Saving unchanged records was causing the tableview to redraw, which was
  mostly invisible, except that if the refresh indicator were running, it
  would twitch.

// FREEBIE
2016-09-09 15:11:40 -04:00
Michael Kirk f3a91c2629 Avoid collision with iOS10 SSKeychain framework (#24)
Our pod SSKeychain was renamed to -> SAMKeychain to avoid collision with
the iOS10 library SSKeychain.

* log failure to write keychain (this seems to only happen on simulator)
* ensure we exit if we fail to set DB cipher key

// FREEBIE
2016-08-18 13:40:48 -04:00
Michael Kirk 0f9a3334c1 Ensure interactions removed when thread is deleted
In theory, this should have already been handled by the
YapDatabaseRelationship extension via edges.

However, in practice, there were situations (cause unknown) where
interactions would exist without an edge to their corresponding thread.

Rather than being clever with the edge/callback machinery, now threads
explicitly delete all their interactions, and interactions delete all
their attachments (when applicable).

Also, a class to clean up spurious interactions / attachments

In the process:
- refactored TSYapDatabaseObject init to specify designated initializer
- added some testing niceties to TSYapDatabaseObject

// FREEBIE
2016-07-31 08:49:01 -07:00
Michael Kirk 2858694ee0 style changes // fix compiler warnings
- log errors
- forward declare where possible
- clang-format
- remove inaccurate file headers
- include Pods in Example app build target to get SignalServiceKit warnings
- Fix those warnings!

// FREEBIE
2016-07-31 08:48:46 -07:00
Frederic Jacobs 5d91a5bd4f Init Commit 2015-12-22 15:51:11 +01:00