firebase-admin 9.4.2 → 9.5.0

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.
Files changed (72) hide show
  1. package/lib/auth/action-code-settings-builder.js +1 -1
  2. package/lib/auth/auth-api-request.js +52 -10
  3. package/lib/auth/auth-config.js +1 -1
  4. package/lib/auth/auth.js +78 -47
  5. package/lib/auth/identifier.js +1 -1
  6. package/lib/auth/index.d.ts +70 -1
  7. package/lib/auth/index.js +1 -1
  8. package/lib/auth/tenant-manager.js +1 -1
  9. package/lib/auth/tenant.js +7 -1
  10. package/lib/auth/token-generator.js +1 -1
  11. package/lib/auth/token-verifier.js +16 -20
  12. package/lib/auth/user-import-builder.js +1 -1
  13. package/lib/auth/user-record.js +1 -1
  14. package/lib/credential/credential-internal.js +1 -1
  15. package/lib/credential/credential.js +1 -1
  16. package/lib/credential/index.d.ts +1 -1
  17. package/lib/credential/index.js +1 -1
  18. package/lib/database/database-internal.js +19 -26
  19. package/lib/database/index.d.ts +1 -1
  20. package/lib/database/index.js +1 -1
  21. package/lib/default-namespace.js +1 -1
  22. package/lib/firebase-app.js +10 -33
  23. package/lib/firebase-namespace-api.d.ts +1 -1
  24. package/lib/firebase-namespace-api.js +1 -1
  25. package/lib/firebase-namespace.d.ts +1 -1
  26. package/lib/firebase-namespace.js +2 -67
  27. package/lib/firestore/firestore-internal.js +1 -19
  28. package/lib/firestore/index.d.ts +1 -1
  29. package/lib/firestore/index.js +1 -1
  30. package/lib/index.d.ts +1 -1
  31. package/lib/index.js +1 -1
  32. package/lib/instance-id/index.d.ts +1 -1
  33. package/lib/instance-id/index.js +1 -1
  34. package/lib/instance-id/instance-id-request-internal.js +1 -1
  35. package/lib/instance-id/instance-id.js +1 -19
  36. package/lib/machine-learning/index.d.ts +1 -1
  37. package/lib/machine-learning/index.js +1 -1
  38. package/lib/machine-learning/machine-learning-api-client.js +1 -1
  39. package/lib/machine-learning/machine-learning-utils.js +1 -1
  40. package/lib/machine-learning/machine-learning.js +1 -20
  41. package/lib/messaging/batch-request-internal.js +1 -1
  42. package/lib/messaging/index.d.ts +4 -4
  43. package/lib/messaging/index.js +1 -1
  44. package/lib/messaging/messaging-api-request-internal.js +1 -1
  45. package/lib/messaging/messaging-errors-internal.js +1 -1
  46. package/lib/messaging/messaging-internal.js +1 -1
  47. package/lib/messaging/messaging.js +1 -19
  48. package/lib/project-management/android-app.js +1 -1
  49. package/lib/project-management/index.d.ts +1 -1
  50. package/lib/project-management/index.js +1 -1
  51. package/lib/project-management/ios-app.js +1 -1
  52. package/lib/project-management/project-management-api-request-internal.js +1 -1
  53. package/lib/project-management/project-management.js +1 -19
  54. package/lib/remote-config/index.d.ts +1 -1
  55. package/lib/remote-config/index.js +1 -1
  56. package/lib/remote-config/remote-config-api-client-internal.js +1 -1
  57. package/lib/remote-config/remote-config.js +5 -21
  58. package/lib/security-rules/index.d.ts +1 -1
  59. package/lib/security-rules/index.js +1 -1
  60. package/lib/security-rules/security-rules-api-client-internal.js +1 -1
  61. package/lib/security-rules/security-rules-internal.js +1 -1
  62. package/lib/security-rules/security-rules.js +1 -10
  63. package/lib/storage/index.d.ts +1 -1
  64. package/lib/storage/index.js +1 -1
  65. package/lib/storage/storage.js +1 -19
  66. package/lib/utils/api-request.js +1 -1
  67. package/lib/utils/deep-copy.js +1 -1
  68. package/lib/utils/error.js +1 -1
  69. package/lib/utils/index.js +1 -1
  70. package/lib/utils/validator.js +1 -1
  71. package/package.json +2 -2
  72. package/lib/firebase-service.js +0 -19
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -23,31 +23,9 @@ var error_1 = require("../utils/error");
23
23
  var validator = require("../utils/validator");
24
24
  var api_request_1 = require("../utils/api-request");
25
25
  var index_1 = require("../utils/index");
26
- /**
27
- * Internals of a Database instance.
28
- */
29
- var DatabaseInternals = /** @class */ (function () {
30
- function DatabaseInternals() {
31
- this.databases = {};
32
- }
33
- /**
34
- * Deletes the service and its associated resources.
35
- *
36
- * @return {Promise<()>} An empty Promise that will be fulfilled when the service is deleted.
37
- */
38
- DatabaseInternals.prototype.delete = function () {
39
- for (var _i = 0, _a = Object.keys(this.databases); _i < _a.length; _i++) {
40
- var dbUrl = _a[_i];
41
- var db = this.databases[dbUrl];
42
- db.INTERNAL.delete();
43
- }
44
- return Promise.resolve(undefined);
45
- };
46
- return DatabaseInternals;
47
- }());
48
26
  var DatabaseService = /** @class */ (function () {
49
27
  function DatabaseService(app) {
50
- this.INTERNAL = new DatabaseInternals();
28
+ this.databases = {};
51
29
  if (!validator.isNonNullObject(app) || !('options' in app)) {
52
30
  throw new error_1.FirebaseDatabaseError({
53
31
  code: 'invalid-argument',
@@ -56,6 +34,21 @@ var DatabaseService = /** @class */ (function () {
56
34
  }
57
35
  this.appInternal = app;
58
36
  }
37
+ /**
38
+ * @internal
39
+ */
40
+ DatabaseService.prototype.delete = function () {
41
+ var _this = this;
42
+ var promises = [];
43
+ for (var _i = 0, _a = Object.keys(this.databases); _i < _a.length; _i++) {
44
+ var dbUrl = _a[_i];
45
+ var db = this.databases[dbUrl];
46
+ promises.push(db.INTERNAL.delete());
47
+ }
48
+ return Promise.all(promises).then(function () {
49
+ _this.databases = {};
50
+ });
51
+ };
59
52
  Object.defineProperty(DatabaseService.prototype, "app", {
60
53
  /**
61
54
  * Returns the app associated with this DatabaseService instance.
@@ -76,7 +69,7 @@ var DatabaseService = /** @class */ (function () {
76
69
  message: 'Database URL must be a valid, non-empty URL string.',
77
70
  });
78
71
  }
79
- var db = this.INTERNAL.databases[dbUrl];
72
+ var db = this.databases[dbUrl];
80
73
  if (typeof db === 'undefined') {
81
74
  var rtdb = require('@firebase/database'); // eslint-disable-line @typescript-eslint/no-var-requires
82
75
  db = rtdb.initStandalone(this.appInternal, dbUrl, index_1.getSdkVersion()).instance;
@@ -90,7 +83,7 @@ var DatabaseService = /** @class */ (function () {
90
83
  db.setRules = function (source) {
91
84
  return rulesClient_1.setRules(source);
92
85
  };
93
- this.INTERNAL.databases[dbUrl] = db;
86
+ this.databases[dbUrl] = db;
94
87
  }
95
88
  return db;
96
89
  };
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -181,7 +181,6 @@ exports.FirebaseAppInternals = FirebaseAppInternals;
181
181
  */
182
182
  var FirebaseApp = /** @class */ (function () {
183
183
  function FirebaseApp(options, name, firebaseInternals_) {
184
- var _this = this;
185
184
  this.firebaseInternals_ = firebaseInternals_;
186
185
  this.services_ = {};
187
186
  this.isDeleted_ = false;
@@ -201,10 +200,6 @@ var FirebaseApp = /** @class */ (function () {
201
200
  ("app named \"" + this.name_ + "\". The \"credential\" property must be an object which implements ") +
202
201
  'the Credential interface.');
203
202
  }
204
- Object.keys(firebaseInternals_.serviceFactories).forEach(function (serviceName) {
205
- // Defer calling createService() until the service is accessed
206
- _this[serviceName] = _this.getService_.bind(_this, serviceName);
207
- });
208
203
  this.INTERNAL = new FirebaseAppInternals(credential);
209
204
  }
210
205
  /**
@@ -361,44 +356,23 @@ var FirebaseApp = /** @class */ (function () {
361
356
  this.firebaseInternals_.removeApp(this.name_);
362
357
  this.INTERNAL.delete();
363
358
  return Promise.all(Object.keys(this.services_).map(function (serviceName) {
364
- return _this.services_[serviceName].INTERNAL.delete();
359
+ var service = _this.services_[serviceName];
360
+ if (isStateful(service)) {
361
+ return service.delete();
362
+ }
363
+ return Promise.resolve();
365
364
  })).then(function () {
366
365
  _this.services_ = {};
367
366
  _this.isDeleted_ = true;
368
367
  });
369
368
  };
370
369
  FirebaseApp.prototype.ensureService_ = function (serviceName, initializer) {
371
- this.checkDestroyed_();
372
- var service;
373
- if (serviceName in this.services_) {
374
- service = this.services_[serviceName];
375
- }
376
- else {
377
- service = initializer();
378
- this.services_[serviceName] = service;
379
- }
380
- return service;
381
- };
382
- /**
383
- * Returns the service instance associated with this FirebaseApp instance (creating it on demand
384
- * if needed). This is used for looking up monkeypatched service instances.
385
- *
386
- * @param serviceName The name of the service instance to return.
387
- * @return The service instance with the provided name.
388
- */
389
- FirebaseApp.prototype.getService_ = function (serviceName) {
390
370
  this.checkDestroyed_();
391
371
  if (!(serviceName in this.services_)) {
392
- this.services_[serviceName] = this.firebaseInternals_.serviceFactories[serviceName](this, this.extendApp_.bind(this));
372
+ this.services_[serviceName] = initializer();
393
373
  }
394
374
  return this.services_[serviceName];
395
375
  };
396
- /**
397
- * Callback function used to extend an App instance at the time of service instance creation.
398
- */
399
- FirebaseApp.prototype.extendApp_ = function (props) {
400
- deep_copy_1.deepExtend(this, props);
401
- };
402
376
  /**
403
377
  * Throws an Error if the FirebaseApp instance has already been deleted.
404
378
  */
@@ -410,3 +384,6 @@ var FirebaseApp = /** @class */ (function () {
410
384
  return FirebaseApp;
411
385
  }());
412
386
  exports.FirebaseApp = FirebaseApp;
387
+ function isStateful(service) {
388
+ return typeof service.delete === 'function';
389
+ }
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -19,7 +19,6 @@
19
19
  Object.defineProperty(exports, "__esModule", { value: true });
20
20
  exports.FirebaseNamespace = exports.FirebaseNamespaceInternals = exports.FIREBASE_CONFIG_VAR = void 0;
21
21
  var fs = require("fs");
22
- var deep_copy_1 = require("./utils/deep-copy");
23
22
  var error_1 = require("./utils/error");
24
23
  var firebase_app_1 = require("./firebase-app");
25
24
  var credential_1 = require("./credential/credential");
@@ -39,9 +38,7 @@ exports.FIREBASE_CONFIG_VAR = 'FIREBASE_CONFIG';
39
38
  var FirebaseNamespaceInternals = /** @class */ (function () {
40
39
  function FirebaseNamespaceInternals(firebase_) {
41
40
  this.firebase_ = firebase_;
42
- this.serviceFactories = {};
43
41
  this.apps_ = {};
44
- this.appHooks_ = {};
45
42
  }
46
43
  /**
47
44
  * Initializes the App instance.
@@ -79,7 +76,6 @@ var FirebaseNamespaceInternals = /** @class */ (function () {
79
76
  }
80
77
  var app = new firebase_app_1.FirebaseApp(options, appName, this);
81
78
  this.apps_[appName] = app;
82
- this.callAppHooks_(app, 'create');
83
79
  return app;
84
80
  };
85
81
  /**
@@ -122,68 +118,7 @@ var FirebaseNamespaceInternals = /** @class */ (function () {
122
118
  throw new error_1.FirebaseAppError(error_1.AppErrorCodes.INVALID_APP_NAME, 'No Firebase app name provided. App name must be a non-empty string.');
123
119
  }
124
120
  var appToRemove = this.app(appName);
125
- this.callAppHooks_(appToRemove, 'delete');
126
- delete this.apps_[appName];
127
- };
128
- /**
129
- * Registers a new service on this Firebase namespace.
130
- *
131
- * @param serviceName The name of the Firebase service to register.
132
- * @param createService A factory method to generate an instance of the Firebase service.
133
- * @param serviceProperties Optional properties to extend this Firebase namespace with.
134
- * @param appHook Optional callback that handles app-related events like app creation and deletion.
135
- * @return The Firebase service's namespace.
136
- */
137
- FirebaseNamespaceInternals.prototype.registerService = function (serviceName, createService, serviceProperties, appHook) {
138
- var _this = this;
139
- var errorMessage;
140
- if (typeof serviceName === 'undefined') {
141
- errorMessage = 'No service name provided. Service name must be a non-empty string.';
142
- }
143
- else if (typeof serviceName !== 'string' || serviceName === '') {
144
- errorMessage = "Invalid service name \"" + serviceName + "\" provided. Service name must be a non-empty string.";
145
- }
146
- else if (serviceName in this.serviceFactories) {
147
- errorMessage = "Firebase service named \"" + serviceName + "\" has already been registered.";
148
- }
149
- if (typeof errorMessage !== 'undefined') {
150
- throw new error_1.FirebaseAppError(error_1.AppErrorCodes.INTERNAL_ERROR, "INTERNAL ASSERT FAILED: " + errorMessage);
151
- }
152
- this.serviceFactories[serviceName] = createService;
153
- if (appHook) {
154
- this.appHooks_[serviceName] = appHook;
155
- }
156
- // The service namespace is an accessor function which takes a FirebaseApp instance
157
- // or uses the default app if no FirebaseApp instance is provided
158
- var serviceNamespace = function (appArg) {
159
- if (typeof appArg === 'undefined') {
160
- appArg = _this.app();
161
- }
162
- // Forward service instance lookup to the FirebaseApp
163
- return appArg[serviceName]();
164
- };
165
- // ... and a container for service-level properties.
166
- if (serviceProperties !== undefined) {
167
- deep_copy_1.deepExtend(serviceNamespace, serviceProperties);
168
- }
169
- // Monkey-patch the service namespace onto the Firebase namespace
170
- this.firebase_[serviceName] = serviceNamespace;
171
- return serviceNamespace;
172
- };
173
- /**
174
- * Calls the app hooks corresponding to the provided event name for each service within the
175
- * provided App instance.
176
- *
177
- * @param app The App instance whose app hooks to call.
178
- * @param eventName The event name representing which app hooks to call.
179
- */
180
- FirebaseNamespaceInternals.prototype.callAppHooks_ = function (app, eventName) {
181
- var _this = this;
182
- Object.keys(this.serviceFactories).forEach(function (serviceName) {
183
- if (_this.appHooks_[serviceName]) {
184
- _this.appHooks_[serviceName](eventName, app);
185
- }
186
- });
121
+ delete this.apps_[appToRemove.name];
187
122
  };
188
123
  /**
189
124
  * Parse the file pointed to by the FIREBASE_CONFIG_VAR, if it exists.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -22,26 +22,8 @@ var error_1 = require("../utils/error");
22
22
  var credential_internal_1 = require("../credential/credential-internal");
23
23
  var validator = require("../utils/validator");
24
24
  var utils = require("../utils/index");
25
- /**
26
- * Internals of a Firestore instance.
27
- */
28
- var FirestoreInternals = /** @class */ (function () {
29
- function FirestoreInternals() {
30
- }
31
- /**
32
- * Deletes the service and its associated resources.
33
- *
34
- * @return {Promise<()>} An empty Promise that will be fulfilled when the service is deleted.
35
- */
36
- FirestoreInternals.prototype.delete = function () {
37
- // There are no resources to clean up.
38
- return Promise.resolve();
39
- };
40
- return FirestoreInternals;
41
- }());
42
25
  var FirestoreService = /** @class */ (function () {
43
26
  function FirestoreService(app) {
44
- this.INTERNAL = new FirestoreInternals();
45
27
  this.firestoreClient = initFirestore(app);
46
28
  this.appInternal = app;
47
29
  }
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
package/lib/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * @license
4
4
  * Copyright 2017 Google Inc.
package/lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -20,23 +20,6 @@ exports.InstanceId = void 0;
20
20
  var error_1 = require("../utils/error");
21
21
  var instance_id_request_internal_1 = require("./instance-id-request-internal");
22
22
  var validator = require("../utils/validator");
23
- /**
24
- * Internals of an InstanceId service instance.
25
- */
26
- var InstanceIdInternals = /** @class */ (function () {
27
- function InstanceIdInternals() {
28
- }
29
- /**
30
- * Deletes the service and its associated resources.
31
- *
32
- * @return {Promise<()>} An empty Promise that will be fulfilled when the service is deleted.
33
- */
34
- InstanceIdInternals.prototype.delete = function () {
35
- // There are no resources to clean up
36
- return Promise.resolve(undefined);
37
- };
38
- return InstanceIdInternals;
39
- }());
40
23
  /**
41
24
  * Gets the {@link InstanceId `InstanceId`} service for the
42
25
  * current app.
@@ -57,7 +40,6 @@ var InstanceId = /** @class */ (function () {
57
40
  * @constructor
58
41
  */
59
42
  function InstanceId(app) {
60
- this.INTERNAL = new InstanceIdInternals();
61
43
  if (!validator.isNonNullObject(app) || !('options' in app)) {
62
44
  throw new error_1.FirebaseInstanceIdError(error_1.InstanceIdClientErrorCode.INVALID_ARGUMENT, 'First argument passed to admin.instanceId() must be a valid Firebase app instance.');
63
45
  }
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -23,24 +23,6 @@ var validator = require("../utils/validator");
23
23
  var machine_learning_utils_1 = require("./machine-learning-utils");
24
24
  var deep_copy_1 = require("../utils/deep-copy");
25
25
  var utils = require("../utils");
26
- /**
27
- * Internals of an ML instance.
28
- */
29
- var MachineLearningInternals = /** @class */ (function () {
30
- function MachineLearningInternals() {
31
- }
32
- /**
33
- * Deletes the service and its associated resources.
34
- *
35
- * @return {Promise<void>} An empty Promise that will be resolved when the
36
- * service is deleted.
37
- */
38
- MachineLearningInternals.prototype.delete = function () {
39
- // There are no resources to clean up.
40
- return Promise.resolve();
41
- };
42
- return MachineLearningInternals;
43
- }());
44
26
  /**
45
27
  * The Firebase Machine Learning class
46
28
  */
@@ -50,7 +32,6 @@ var MachineLearning = /** @class */ (function () {
50
32
  * @constructor
51
33
  */
52
34
  function MachineLearning(app) {
53
- this.INTERNAL = new MachineLearningInternals();
54
35
  if (!validator.isNonNullObject(app) || !('options' in app)) {
55
36
  throw new error_1.FirebaseError({
56
37
  code: 'machine-learning/invalid-argument',
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2019 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -56,13 +56,13 @@ export declare namespace messaging {
56
56
  apns?: ApnsConfig;
57
57
  fcmOptions?: FcmOptions;
58
58
  }
59
- interface TokenMessage extends BaseMessage {
59
+ export interface TokenMessage extends BaseMessage {
60
60
  token: string;
61
61
  }
62
- interface TopicMessage extends BaseMessage {
62
+ export interface TopicMessage extends BaseMessage {
63
63
  topic: string;
64
64
  }
65
- interface ConditionMessage extends BaseMessage {
65
+ export interface ConditionMessage extends BaseMessage {
66
66
  condition: string;
67
67
  }
68
68
  /**
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2019 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * @license
@@ -156,23 +156,6 @@ function mapRawResponseToTopicManagementResponse(response) {
156
156
  }
157
157
  return result;
158
158
  }
159
- /**
160
- * Internals of a Messaging instance.
161
- */
162
- var MessagingInternals = /** @class */ (function () {
163
- function MessagingInternals() {
164
- }
165
- /**
166
- * Deletes the service and its associated resources.
167
- *
168
- * @return {Promise<()>} An empty Promise that will be fulfilled when the service is deleted.
169
- */
170
- MessagingInternals.prototype.delete = function () {
171
- // There are no resources to clean up.
172
- return Promise.resolve(undefined);
173
- };
174
- return MessagingInternals;
175
- }());
176
159
  /**
177
160
  * Messaging service bound to the provided app.
178
161
  */
@@ -191,7 +174,6 @@ var Messaging = /** @class */ (function () {
191
174
  * @return The `Messaging` service for the current app.
192
175
  */
193
176
  function Messaging(app) {
194
- this.INTERNAL = new MessagingInternals();
195
177
  if (!validator.isNonNullObject(app) || !('options' in app)) {
196
178
  throw new error_1.FirebaseMessagingError(error_1.MessagingClientErrorCode.INVALID_ARGUMENT, 'First argument passed to admin.messaging() must be a valid Firebase app instance.');
197
179
  }
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2018 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  /*!
3
3
  * Copyright 2020 Google Inc.
4
4
  *
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2020 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2018 Google Inc.
@@ -1,4 +1,4 @@
1
- /*! firebase-admin v9.4.2 */
1
+ /*! firebase-admin v9.5.0 */
2
2
  "use strict";
3
3
  /*!
4
4
  * Copyright 2018 Google Inc.