Skip to content

Commit 447db7b

Browse files
author
Ian White
committed
Changing language_override restarts session
1 parent 863b3c2 commit 447db7b

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

jest.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
module.exports = {
22
preset: 'ts-jest',
33
testEnvironment: 'jsdom',
4-
};
4+
};

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@reclaim-ai/react-intercom-hook",
3-
"version": "2.0.5",
3+
"version": "2.0.6",
44
"description": "React hook for Intercom.io",
55
"repository": "git://github.com/reclaim-ai/react-intercom-hook.git",
66
"keywords": [

src/useIntercom.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export const useIntercom = (
1818
undefined !== intercom.settings[attr] &&
1919
settings[attr] !== intercom.settings[attr];
2020

21-
if (!!intercom.appId && ["app_id", "user_id", "email"].some(isChanged)) {
21+
if (!!intercom.appId && ["app_id", "user_id", "email", "language_override"].some(isChanged)) {
2222
// app_id or user changed, restart session
2323
intercom.command("shutdown");
2424
if (settings.app_id) intercom.boot(settings);

0 commit comments

Comments
 (0)