Skip to content

Fix result of a login not actually being handled

nic547 requested to merge nic547/osmybiz:merge_login_fix into develop

Per the documentation OSMAuth doesn't appear to return a promise for it's .authenticate() function. When logging in, we currently do not actually await a Promise, instead the Continuation is run immediately and assumes that the login did word and the user authorized OSMyBiz. This leads to the effect that the login process always appears to succeed and stores a broken user in the auth store, leading to bugs in things like the watchlist.

This MR updates login() to create a Promise that is returned and later resolved/rejected as a callback by OSMAuth.

Merge request reports