Fixes #376

https://github.com/couchbase/couchbase-lite-android/issues/376