@schemavaults/auth-common 0.10.3 → 0.10.5
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const ERROR_IDS: readonly ["unknown", "bad_request", "app_id_not_found", "api_server_id_not_found", "unauthenticated", "forbidden", "account_disabled", "load_user_data_failure", "internal_server_error", "load_server_config_failure", "server_misconfiguration"];
|
|
1
|
+
declare const ERROR_IDS: readonly ["unknown", "bad_request", "app_id_not_found", "api_server_id_not_found", "unauthenticated", "forbidden", "account_disabled", "load_user_data_failure", "internal_server_error", "load_server_config_failure", "server_misconfiguration", "account_not_in_organization"];
|
|
2
2
|
export type SchemaVaultsAuthErrorId = (typeof ERROR_IDS)[number];
|
|
3
3
|
export declare const ERROR_MESSAGE_CATALOG: Record<SchemaVaultsAuthErrorId, string>;
|
|
4
4
|
export declare function isValidErrorId(id: string): id is SchemaVaultsAuthErrorId;
|
|
@@ -10,6 +10,7 @@ const ERROR_IDS = [
|
|
|
10
10
|
"internal_server_error",
|
|
11
11
|
"load_server_config_failure",
|
|
12
12
|
"server_misconfiguration",
|
|
13
|
+
"account_not_in_organization",
|
|
13
14
|
];
|
|
14
15
|
export const ERROR_MESSAGE_CATALOG = {
|
|
15
16
|
unknown: "An unknown error occurred",
|
|
@@ -23,6 +24,7 @@ export const ERROR_MESSAGE_CATALOG = {
|
|
|
23
24
|
internal_server_error: "There was a problem in the SchemaVaults backend logic and something caused a crash!",
|
|
24
25
|
load_server_config_failure: "There was a problem loading server configuration settings.",
|
|
25
26
|
server_misconfiguration: "The server does not appear to be configured properly. If you are the site admin, please see the logs for more details.",
|
|
27
|
+
account_not_in_organization: "Your account is not a member of the organization required for the attempted action.",
|
|
26
28
|
};
|
|
27
29
|
export function isValidErrorId(id) {
|
|
28
30
|
return ERROR_IDS.includes(id);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-error-message-catalog.js","sourceRoot":"","sources":["../src/auth-error-message-catalog.ts"],"names":[],"mappings":"AAAA,MAAM,SAAS,GAAG;IAChB,SAAS;IACT,aAAa;IACb,kBAAkB;IAClB,yBAAyB;IACzB,iBAAiB;IACjB,WAAW;IACX,kBAAkB;IAClB,wBAAwB;IACxB,uBAAuB;IACvB,4BAA4B;IAC5B,yBAAyB;
|
|
1
|
+
{"version":3,"file":"auth-error-message-catalog.js","sourceRoot":"","sources":["../src/auth-error-message-catalog.ts"],"names":[],"mappings":"AAAA,MAAM,SAAS,GAAG;IAChB,SAAS;IACT,aAAa;IACb,kBAAkB;IAClB,yBAAyB;IACzB,iBAAiB;IACjB,WAAW;IACX,kBAAkB;IAClB,wBAAwB;IACxB,uBAAuB;IACvB,4BAA4B;IAC5B,yBAAyB;IACzB,6BAA6B;CACO,CAAC;AAIvC,MAAM,CAAC,MAAM,qBAAqB,GAA4C;IAC5E,OAAO,EAAE,2BAA2B;IACpC,WAAW,EAAE,wCAAwC;IACrD,gBAAgB,EAAE,kCAAkC;IACpD,uBAAuB,EAAE,wCAAwC;IACjE,eAAe,EACb,iGAAiG;IACnG,SAAS,EACP,gHAAgH;IAClH,gBAAgB,EAAE,iCAAiC;IACnD,sBAAsB,EACpB,4EAA4E;IAC9E,qBAAqB,EACnB,qFAAqF;IACvF,0BAA0B,EACxB,4DAA4D;IAC9D,uBAAuB,EACrB,wHAAwH;IAC1H,2BAA2B,EACzB,qFAAqF;CACxF,CAAC;AAEF,MAAM,UAAU,cAAc,CAAC,EAAU;IACvC,OAAO,SAAS,CAAC,QAAQ,CAAC,EAA8C,CAAC,CAAC;AAC5E,CAAC"}
|