@bzr/bazaar
Advanced tools
Comparing version 1.1.1 to 1.1.2
@@ -61,2 +61,8 @@ import io from 'socket.io-client'; | ||
} | ||
function isNoAppUserError(e) { | ||
return e instanceof BazaarError && e.type === ErrorTypes.DatabaseDoesNotExist; | ||
} | ||
function isNoPermissionError(e) { | ||
return e instanceof BazaarError && e.type === ErrorTypes.NoPermission; | ||
} | ||
/** | ||
@@ -1513,2 +1519,2 @@ * Generates a secure random string using the browser crypto functions | ||
export { BazaarApp, BazaarError, CollectionAPI, CollectionsAPI, ErrorTypes, LoginType, OrderByType, PermissionType, PermissionsAPI, SocialAPI }; | ||
export { BazaarApp, BazaarError, CollectionAPI, CollectionsAPI, ErrorTypes, LoginType, OrderByType, PermissionType, PermissionsAPI, SocialAPI, isNoAppUserError, isNoPermissionError }; |
@@ -9,3 +9,3 @@ import { CollectionAPI } from "./api/collection"; | ||
*/ | ||
export { ErrorTypes, BazaarError } from "./utils"; | ||
export { ErrorTypes, BazaarError, isNoAppUserError, isNoPermissionError } from "./utils"; | ||
export { CollectionAPI } from "./api/collection"; | ||
@@ -12,0 +12,0 @@ export { CollectionsAPI } from "./api/collections"; |
@@ -19,4 +19,4 @@ /** | ||
} | ||
export declare function isNoAppUserError(e: Error): boolean; | ||
export declare function isNoPermissionError(e: Error): boolean; | ||
export declare function isNoAppUserError(e: unknown): boolean; | ||
export declare function isNoPermissionError(e: unknown): boolean; | ||
/** | ||
@@ -23,0 +23,0 @@ * Generates a secure random string using the browser crypto functions |
{ | ||
"name": "@bzr/bazaar", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"description": "The Bazaar SDK. Conveniently use Bazaar with your app in the browser.", | ||
@@ -5,0 +5,0 @@ "files": [ |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
172265
2901