scout-types 1.0.15 → 1.0.16

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.
@@ -8,7 +8,7 @@ export declare class Scout {
8
8
  readonly scout_id: string;
9
9
  readonly name: string;
10
10
  readonly active: boolean;
11
- readonly state_id: StateID;
11
+ readonly state_id?: StateID;
12
12
  readonly district?: number;
13
13
  readonly party_id: PartyID;
14
14
  readonly tone_description_refresh: boolean;
@@ -41,7 +41,7 @@ export class Scout {
41
41
  typeof scout.scout_id === "string" &&
42
42
  typeof scout.name === "string" &&
43
43
  typeof scout.active === "boolean" &&
44
- is_state_id(scout.state_id) &&
44
+ (scout.state_id === undefined || is_state_id(scout.state_id)) &&
45
45
  (scout.district === undefined || typeof scout.district === "number") &&
46
46
  is_party_id(scout.party_id) &&
47
47
  typeof scout.tone_description_refresh === "boolean" &&
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scout-types",
3
- "version": "1.0.15",
3
+ "version": "1.0.16",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "directories": {
@@ -9,7 +9,7 @@ export class Scout {
9
9
  readonly scout_id : string
10
10
  readonly name : string
11
11
  readonly active : boolean
12
- readonly state_id : StateID
12
+ readonly state_id? : StateID
13
13
  readonly district? : number
14
14
  readonly party_id : PartyID
15
15
  readonly tone_description_refresh : boolean
@@ -46,7 +46,7 @@ export class Scout {
46
46
  typeof scout.scout_id === "string" &&
47
47
  typeof scout.name === "string" &&
48
48
  typeof scout.active === "boolean" &&
49
- is_state_id(scout.state_id) &&
49
+ (scout.state_id === undefined || is_state_id(scout.state_id)) &&
50
50
  (scout.district === undefined || typeof scout.district === "number") &&
51
51
  is_party_id(scout.party_id) &&
52
52
  typeof scout.tone_description_refresh === "boolean" &&