From e94926259f5351b14731318df1168928f49abd11 Mon Sep 17 00:00:00 2001 From: Lloyd Hilaiel <lloyd@hilaiel.com> Date: Fri, 6 Apr 2012 14:44:53 -0600 Subject: [PATCH] (re)add optional callback argument to navigator.id.logout(), fixes accidental API breakage in dev - closes #1399 --- resources/static/include_js/include.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resources/static/include_js/include.js b/resources/static/include_js/include.js index bc7c6e99f..7186f99fd 100644 --- a/resources/static/include_js/include.js +++ b/resources/static/include_js/include.js @@ -1101,11 +1101,14 @@ } }, // logout from the current website - logout: function() { + // NOTE: callback argument will be deprecated when experimental API lands, to + // be replaced with the .onlogout observer of the watch api. + logout: function(callback) { // allocate iframe if it is not allocated _open_hidden_iframe(); // send logout message commChan.notify({ method: 'logout' }); + if (typeof callback === 'function') setTimeout(callback, 0); }, // get an assertion get: function(callback, options) { -- GitLab