Finished first working promise pattern facade of PouchDB