Skip to content

Commit 7a1eaa1

Browse files
authored
Merge pull request #30 from pazdera/xd-auth-issue
bugfix: Make sure the initSession callback isn't called 2x
2 parents 5074354 + 63e9078 commit 7a1eaa1

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

dist/kano-world-sdk.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ module.exports = function (config) {
134134

135135
// The current website is either KW or running inside Electron, we read directly the locaStorage
136136
if (isKW || isElectron) {
137-
p = onToken(token || localStorage.getItem('KW_TOKEN'));
137+
return onToken(token || localStorage.getItem('KW_TOKEN'));
138138
}
139139
// Otherwise, contact KW to get the toekn throught the iframe
140140
xdAuth.getCrossToken(function (err, tk) {

lib/core/auth.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ module.exports = function (config) {
7272

7373
// The current website is either KW or running inside Electron, we read directly the locaStorage
7474
if (isKW || isElectron) {
75-
p = onToken(token || localStorage.getItem('KW_TOKEN'));
75+
return onToken(token || localStorage.getItem('KW_TOKEN'));
7676
}
7777
// Otherwise, contact KW to get the toekn throught the iframe
7878
xdAuth.getCrossToken(function (err, tk) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "kano-world-sdk",
3-
"version": "3.0.15",
3+
"version": "3.0.16",
44
"description": "Kano World SDK",
55
"main": "lib/index.js",
66
"scripts": {

0 commit comments

Comments
 (0)