(Better describes what it does, and avoids confusion with the
mkws_config property of the same name.)
Check before running a search whether we're authenticated.
(It's because we were not that auto-searches were failing on
the first call of a new session -- the search was being sent
before the authentication response was received.)
// Set up namespace and some state.
var mkws = {
+ authenticated: false,
filters: [],
};
function newSearch(query)
{
+ if (!mkws.authenticated) {
+ alert("searching before authentication");
+ return;
+ }
+
mkws.filters = []
redraw_navi();
resetPage();
}
debug("Service proxy auth successfully done");
- mkws.service_proxy_auth = true;
+ mkws.authenticated = true;
});
}