Updated dependency and made mostly naming changes
All checks were successful
Publish to Private NPM Registry / publish (push) Successful in 29s
All checks were successful
Publish to Private NPM Registry / publish (push) Successful in 29s
This commit is contained in:
parent
b67f059eda
commit
859aee5939
3 changed files with 15 additions and 14 deletions
|
|
@ -39,7 +39,7 @@
|
||||||
"create-ba-web-app": "node ./bin/create-project.js"
|
"create-ba-web-app": "node ./bin/create-project.js"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@BridgemanAccessible/ba-auth": "^1.0.36",
|
"@BridgemanAccessible/ba-auth": "^1.0.37",
|
||||||
"@BridgemanAccessible/ba-logging": "^1.0.1",
|
"@BridgemanAccessible/ba-logging": "^1.0.1",
|
||||||
"express": "^4.19.2",
|
"express": "^4.19.2",
|
||||||
"fs-extra": "^11.2.0",
|
"fs-extra": "^11.2.0",
|
||||||
|
|
|
||||||
|
|
@ -103,7 +103,7 @@ type OAuthAppOptions<T extends BridgemanAccessibleAppClaims> = T & BasicOAuthApp
|
||||||
export class OAuthApp<TCustomClaims extends BridgemanAccessibleAppClaims> extends App {
|
export class OAuthApp<TCustomClaims extends BridgemanAccessibleAppClaims> extends App {
|
||||||
private onAuth: OnAuthCallback;
|
private onAuth: OnAuthCallback;
|
||||||
private saveSecret: (secret: string) => void | Promise<void>;
|
private saveSecret: (secret: string) => void | Promise<void>;
|
||||||
private getAccessToken: () => Promise<string>;
|
private getSecret: () => Promise<string>;
|
||||||
|
|
||||||
private options: OAuthAppOptions<TCustomClaims>;
|
private options: OAuthAppOptions<TCustomClaims>;
|
||||||
|
|
||||||
|
|
@ -134,6 +134,7 @@ export class OAuthApp<TCustomClaims extends BridgemanAccessibleAppClaims> extend
|
||||||
*
|
*
|
||||||
* @param onAuth The callback to call when a user logs in
|
* @param onAuth The callback to call when a user logs in
|
||||||
* @param saveSecret The callback to call to save the secret
|
* @param saveSecret The callback to call to save the secret
|
||||||
|
* @param getSecret The callback to call to get the secret
|
||||||
* @param options The options for the OAuth app
|
* @param options The options for the OAuth app
|
||||||
* @param options.baseAppUrl The base URL of the app
|
* @param options.baseAppUrl The base URL of the app
|
||||||
* @param options.client_abbreviation The abbreviation of the app (used for user properties associated with the app)
|
* @param options.client_abbreviation The abbreviation of the app (used for user properties associated with the app)
|
||||||
|
|
@ -156,13 +157,13 @@ export class OAuthApp<TCustomClaims extends BridgemanAccessibleAppClaims> extend
|
||||||
constructor(
|
constructor(
|
||||||
onAuth: OnAuthCallback,
|
onAuth: OnAuthCallback,
|
||||||
saveSecret: (secret: string) => void | Promise<void>,
|
saveSecret: (secret: string) => void | Promise<void>,
|
||||||
getAccessToken: () => Promise<string>,
|
getSecret: () => Promise<string>,
|
||||||
options?: OAuthAppOptions<TCustomClaims>
|
options?: OAuthAppOptions<TCustomClaims>
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
this.onAuth = onAuth;
|
this.onAuth = onAuth;
|
||||||
this.saveSecret = saveSecret;
|
this.saveSecret = saveSecret;
|
||||||
this.getAccessToken = getAccessToken;
|
this.getSecret = getSecret;
|
||||||
this.options = options ?? {} as OAuthAppOptions<TCustomClaims>;
|
this.options = options ?? {} as OAuthAppOptions<TCustomClaims>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -204,7 +205,7 @@ export class OAuthApp<TCustomClaims extends BridgemanAccessibleAppClaims> extend
|
||||||
baseAppUrl,
|
baseAppUrl,
|
||||||
this.onAuth,
|
this.onAuth,
|
||||||
this.saveSecret,
|
this.saveSecret,
|
||||||
this.getAccessToken,
|
this.getSecret,
|
||||||
{
|
{
|
||||||
client_abbreviation: appAbbrv,
|
client_abbreviation: appAbbrv,
|
||||||
subscription_required: this.options.subscription_required ?? false,
|
subscription_required: this.options.subscription_required ?? false,
|
||||||
|
|
|
||||||
18
yarn.lock
18
yarn.lock
|
|
@ -2,12 +2,12 @@
|
||||||
# yarn lockfile v1
|
# yarn lockfile v1
|
||||||
|
|
||||||
|
|
||||||
"@BridgemanAccessible/ba-auth@^1.0.36":
|
"@BridgemanAccessible/ba-auth@^1.0.37":
|
||||||
version "1.0.36"
|
version "1.0.37"
|
||||||
resolved "https://npm.pkg.bridgemanaccessible.ca/@BridgemanAccessible/ba-auth/-/ba-auth-1.0.36.tgz#7654d37d3e078cd0c3b226d05b15e873437133b5"
|
resolved "https://npm.pkg.bridgemanaccessible.ca/@BridgemanAccessible/ba-auth/-/ba-auth-1.0.37.tgz#70c6d56fbe2f6111ead234fe40c79acea342ae51"
|
||||||
integrity sha512-9e1OYDhUhkl38FmL2wMhPjfqsy2Pt/+o0WQtHne2cPMDAoz4h0cat9NE3lGDnCn1LMkUXaCXvNXoRUDJkUpFJw==
|
integrity sha512-YRiC5MUV+fsYaTPWnGnPuHgfJ5juYvWrqyTVdtgVM2iIbqSCSTQsLrLdjDdnRn5vFRDHDv6ypJuTu6crxcDJCQ==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@BridgemanAccessible/ba-auth_adapters" "^1.0.1"
|
"@BridgemanAccessible/ba-auth_adapters" "^1.0.2"
|
||||||
"@BridgemanAccessible/ba-auth_keystore" "^1.0.1"
|
"@BridgemanAccessible/ba-auth_keystore" "^1.0.1"
|
||||||
"@BridgemanAccessible/ba-logging" "^1.0.1"
|
"@BridgemanAccessible/ba-logging" "^1.0.1"
|
||||||
argon2 "^0.40.1"
|
argon2 "^0.40.1"
|
||||||
|
|
@ -19,10 +19,10 @@
|
||||||
psl "^1.15.0"
|
psl "^1.15.0"
|
||||||
uuid "^9.0.1"
|
uuid "^9.0.1"
|
||||||
|
|
||||||
"@BridgemanAccessible/ba-auth_adapters@^1.0.1":
|
"@BridgemanAccessible/ba-auth_adapters@^1.0.2":
|
||||||
version "1.0.1"
|
version "1.0.2"
|
||||||
resolved "https://npm.pkg.bridgemanaccessible.ca/@BridgemanAccessible/ba-auth_adapters/-/ba-auth_adapters-1.0.1.tgz#ba5a4bcc7e2a8a22a539165140b1900e618db535"
|
resolved "https://npm.pkg.bridgemanaccessible.ca/@BridgemanAccessible/ba-auth_adapters/-/ba-auth_adapters-1.0.2.tgz#a546759a8bc0f2d0eb1a211b144870f8414a3dd9"
|
||||||
integrity sha512-RigrC3wbDB+MICgLyHpyunrVXUa6NpT14jVk01DYZPIXgbLURfTJhhNB8Xm8AP5/t3onMBvGoz3hNNON6jxOqQ==
|
integrity sha512-k8pzWTJUGdPEPtSZilTHDTydre/O0yM8YaNlXdq4cCRaIPJHc6Hyn94wZWNPd2nZsnUsvLj7gXWPaHphY8E1Ug==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@BridgemanAccessible/ba-logging" "^1.0.1"
|
"@BridgemanAccessible/ba-logging" "^1.0.1"
|
||||||
express "^5.2.1"
|
express "^5.2.1"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue