leapcode/leap_mx — pull request #44 by bwgpro (2014-09-04 19:08:52+00:00)
Title: Leap mx will not stop working for everyone if an user is inconsistent

When an user gets into an inconsistent state (has no user_id), the leap_mx cannot retrieve keys for any user whose record is after that one on couch (the iterator breaks on fetching the user_id).

This change makes two things:
- A warning on the logs that an user is in inconsistent state (this might help debug the cause of the inconsistency)
- A skip of the key lookup for the inconsistent user

This way even if an user enters an inconsistent state, the others users of the LEAP provider will not be affected, also the fact that an user is inconsistent will be logged properly.