@etsoo/appscript 1.5.23 → 1.5.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -135,8 +135,6 @@ class CoreAppTest extends CoreApp<
135
135
  new WindowStorage(),
136
136
  'SmartERP'
137
137
  );
138
-
139
- this.deviceId = 'abcd1234';
140
138
  }
141
139
 
142
140
  freshCountdownUI(callback?: () => PromiseLike<unknown>): void {
@@ -90,7 +90,6 @@ export declare abstract class CoreApp<U extends IUser, S extends IAppSettings, N
90
90
  * Device id, randome string from ServiceBase.InitCallAsync
91
91
  */
92
92
  get deviceId(): string;
93
- protected set deviceId(value: string);
94
93
  /**
95
94
  * Label delegate
96
95
  */
@@ -39,14 +39,8 @@ class CoreApp {
39
39
  * Device id, randome string from ServiceBase.InitCallAsync
40
40
  */
41
41
  get deviceId() {
42
- if (this._deviceId === '') {
43
- throw new Error('Device id is empty');
44
- }
45
42
  return this._deviceId;
46
43
  }
47
- set deviceId(value) {
48
- this._deviceId = value;
49
- }
50
44
  /**
51
45
  * Label delegate
52
46
  */
@@ -233,7 +227,7 @@ class CoreApp {
233
227
  async restore() {
234
228
  // Devices
235
229
  const devices = this.storage.getPersistedData(this.fields.devices, []);
236
- if (this.deviceId === '') {
230
+ if (this._deviceId === '') {
237
231
  // First vist, restore and keep the source
238
232
  this.storage.copyFrom(this.persistedFields, false);
239
233
  // Reset device id
@@ -90,7 +90,6 @@ export declare abstract class CoreApp<U extends IUser, S extends IAppSettings, N
90
90
  * Device id, randome string from ServiceBase.InitCallAsync
91
91
  */
92
92
  get deviceId(): string;
93
- protected set deviceId(value: string);
94
93
  /**
95
94
  * Label delegate
96
95
  */
@@ -36,14 +36,8 @@ export class CoreApp {
36
36
  * Device id, randome string from ServiceBase.InitCallAsync
37
37
  */
38
38
  get deviceId() {
39
- if (this._deviceId === '') {
40
- throw new Error('Device id is empty');
41
- }
42
39
  return this._deviceId;
43
40
  }
44
- set deviceId(value) {
45
- this._deviceId = value;
46
- }
47
41
  /**
48
42
  * Label delegate
49
43
  */
@@ -230,7 +224,7 @@ export class CoreApp {
230
224
  async restore() {
231
225
  // Devices
232
226
  const devices = this.storage.getPersistedData(this.fields.devices, []);
233
- if (this.deviceId === '') {
227
+ if (this._deviceId === '') {
234
228
  // First vist, restore and keep the source
235
229
  this.storage.copyFrom(this.persistedFields, false);
236
230
  // Reset device id
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@etsoo/appscript",
3
- "version": "1.5.23",
3
+ "version": "1.5.24",
4
4
  "description": "Applications shared TypeScript framework",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/mjs/index.js",
@@ -170,14 +170,8 @@ export abstract class CoreApp<
170
170
  * Device id, randome string from ServiceBase.InitCallAsync
171
171
  */
172
172
  get deviceId() {
173
- if (this._deviceId === '') {
174
- throw new Error('Device id is empty');
175
- }
176
173
  return this._deviceId;
177
174
  }
178
- protected set deviceId(value: string) {
179
- this._deviceId = value;
180
- }
181
175
 
182
176
  /**
183
177
  * Label delegate
@@ -433,7 +427,7 @@ export abstract class CoreApp<
433
427
  []
434
428
  );
435
429
 
436
- if (this.deviceId === '') {
430
+ if (this._deviceId === '') {
437
431
  // First vist, restore and keep the source
438
432
  this.storage.copyFrom(this.persistedFields, false);
439
433