fix: navigator not defined in test environment
This commit is contained in:
@@ -111,7 +111,7 @@ export class GatewayClient {
|
|||||||
commands: [],
|
commands: [],
|
||||||
permissions: {},
|
permissions: {},
|
||||||
auth: { token: this.authToken },
|
auth: { token: this.authToken },
|
||||||
locale: navigator.language || 'en',
|
locale: (typeof navigator !== 'undefined' ? navigator.language : undefined) || 'en',
|
||||||
userAgent: `pinchchat/${__APP_VERSION__}`,
|
userAgent: `pinchchat/${__APP_VERSION__}`,
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
log('connected!', res);
|
log('connected!', res);
|
||||||
|
|||||||
Reference in New Issue
Block a user