triangle-utils 1.4.164 → 1.4.165

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.
@@ -22,6 +22,7 @@ export declare class GlobalConfig {
22
22
  readonly youtube_api_key: string;
23
23
  readonly xai_api_key: string;
24
24
  readonly ballotpedia_api_key: string;
25
+ readonly brave_api_key: string;
25
26
  readonly [x: string]: any;
26
27
  constructor(global_config: GlobalConfig);
27
28
  static is(global_config: any): global_config is GlobalConfig;
@@ -22,6 +22,7 @@ export class GlobalConfig {
22
22
  youtube_api_key;
23
23
  xai_api_key;
24
24
  ballotpedia_api_key;
25
+ brave_api_key;
25
26
  constructor(global_config) {
26
27
  if (!GlobalConfig.is(global_config)) {
27
28
  throw Error("Invalid input.");
@@ -49,6 +50,7 @@ export class GlobalConfig {
49
50
  this.youtube_api_key = global_config.youtube_api_key;
50
51
  this.xai_api_key = global_config.xai_api_key;
51
52
  this.ballotpedia_api_key = global_config.ballotpedia_api_key;
53
+ this.brave_api_key = global_config.brave_api_key;
52
54
  }
53
55
  static is(global_config) {
54
56
  return (global_config !== undefined &&
@@ -74,6 +76,7 @@ export class GlobalConfig {
74
76
  typeof global_config.twitter_api_key === "string" &&
75
77
  typeof global_config.youtube_api_key === "string" &&
76
78
  typeof global_config.xai_api_key === "string" &&
77
- typeof global_config.ballotpedia_api_key === "string");
79
+ typeof global_config.ballotpedia_api_key === "string" &&
80
+ typeof global_config.brave_api_key === "string");
78
81
  }
79
82
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-utils",
3
- "version": "1.4.164",
3
+ "version": "1.4.165",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "directories": {
@@ -22,6 +22,7 @@ export class GlobalConfig {
22
22
  readonly youtube_api_key : string
23
23
  readonly xai_api_key : string
24
24
  readonly ballotpedia_api_key : string
25
+ readonly brave_api_key : string
25
26
  readonly [x : string] : any
26
27
 
27
28
  constructor(global_config : GlobalConfig) {
@@ -51,6 +52,7 @@ export class GlobalConfig {
51
52
  this.youtube_api_key = global_config.youtube_api_key
52
53
  this.xai_api_key = global_config.xai_api_key
53
54
  this.ballotpedia_api_key = global_config.ballotpedia_api_key
55
+ this.brave_api_key = global_config.brave_api_key
54
56
  }
55
57
 
56
58
  static is(global_config : any) : global_config is GlobalConfig {
@@ -78,7 +80,8 @@ export class GlobalConfig {
78
80
  typeof global_config.twitter_api_key === "string" &&
79
81
  typeof global_config.youtube_api_key === "string" &&
80
82
  typeof global_config.xai_api_key === "string" &&
81
- typeof global_config.ballotpedia_api_key === "string"
83
+ typeof global_config.ballotpedia_api_key === "string" &&
84
+ typeof global_config.brave_api_key === "string"
82
85
  )
83
86
  }
84
87
  }