Переглянути джерело

Fix work indicator (#558)

Due to a bug in the Android app, the `isWork` flag was not always
defined.
Danilo Bargen 7 роки тому
батько
коміт
e318ef84a6
2 змінених файлів з 2 додано та 2 видалено
  1. 1 1
      src/services/webclient.ts
  2. 1 1
      src/threema.d.ts

+ 1 - 1
src/services/webclient.ts

@@ -2410,7 +2410,7 @@ export class WebClientService {
             device: data.device,
             os: data.os,
             osVersion: data.osVersion,
-            isWork: data.isWork,
+            isWork: hasValue(data.isWork) ? data.isWork : false,  // TODO: Backwards compat hack, remove after 08/2019
             pushToken: data.pushToken,
             configuration: {
                 voipEnabled: getOrDefault<boolean>(data.configuration.voipEnabled, true),

+ 1 - 1
src/threema.d.ts

@@ -193,7 +193,7 @@ declare namespace threema {
 
     const enum IdentityType {
         Regular = 0,
-        Work,
+        Work = 1,
     }
 
     /**