@lighthouse/sdk
Advanced tools
Comparing version 7.1.2-beta to 7.1.2-beta-2
@@ -103,3 +103,8 @@ 'use strict'; | ||
NOTE | ||
We need to handle this here for when users have never logged into the app before. The speakerId is stored on a users' userApplication, but if they're a new user, when they first login then they won't have a speakerId in the place. So what we do here is use the speakerId returned by messagesRegistration and set that on the speakerbox configuration for that user | ||
We need to handle this here for when users have never logged into the app | ||
before. The speakerId is stored on a users' userApplication, but if | ||
they're a new user, when they first login then they won't have a speakerId | ||
in the place. So what we do here is use the speakerId returned by | ||
messagesRegistration and set that on the speakerbox configuration for that | ||
user | ||
*/ | ||
@@ -117,3 +122,3 @@ case _applicationUsers.actions.MESSAGES_REGISTRATION_SUCCESS: | ||
return userApplication.setIn(['application', 'speakerbox', 'speakerId'], speakerId); | ||
return userApplication.setIn(['speakerbox', 'speakerId'], speakerId); | ||
})) | ||
@@ -120,0 +125,0 @@ }; |
@@ -84,3 +84,3 @@ /* | ||
return userApplication.setIn(['application', 'speakerbox', 'speakerId'], speakerId) | ||
return userApplication.setIn(['speakerbox', 'speakerId'], speakerId) | ||
})) | ||
@@ -87,0 +87,0 @@ default: |
@@ -151,8 +151,14 @@ import { | ||
name: 'Application 2', | ||
speakerbox: { | ||
speakerId: 's1', | ||
} | ||
}, | ||
speakerbox: { | ||
speakerId: 's1', | ||
} | ||
}] | ||
}) | ||
speakerIdSelector({ | ||
app: { | ||
applicationId: 'a2', | ||
}, | ||
userApplications: result, | ||
}).should.eql('s1') | ||
}) | ||
@@ -159,0 +165,0 @@ |
{ | ||
"name": "@lighthouse/sdk", | ||
"version": "7.1.2-beta", | ||
"version": "7.1.2-beta-2", | ||
"description": "Lighthouse.io SDK for JavaScript applications", | ||
@@ -5,0 +5,0 @@ "main": "build/index.js", |
575750
16511