bitpay/copay — pull request #1227 by matiu (2014-08-28 22:36:03+00:00)
Title: Bug/networking2

WARNING: Depends on: https://github.com/bitpay/insight-api/pull/170

Fixes some minor bugs in the new networking protocol:

1. fixes the synchronisation problem solved https://github.com/bitpay/copay/pull/1214, in a better way, with server help.
2. handle the 'no messages' event, by triggering a resync from the peers
3. adds a resync request to the refresh button
4. updates the `lastTimestamp` *after* processing messages, in case something fails
5. syncs from lastTimestamp + 1 to prevent processing the last messages