refactor: add setter for jwtToken

This commit is contained in:
Derrick Hammer 2024-03-13 18:13:24 -04:00
parent 0f3de13f52
commit 070b117089
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 6 additions and 1 deletions

View File

@ -28,7 +28,8 @@ import * as URL from 'url';
export class AccountApi {
private apiUrl: string;
private jwtToken?: string;
private _jwtToken?: string;
constructor(apiUrl: string) {
let apiUrlParsed = new URL.URL(apiUrl);
@ -37,6 +38,10 @@ export class AccountApi {
this.apiUrl = apiUrlParsed.toString();
}
set jwtToken(value: string) {
this._jwtToken = value;
}
public static create(apiUrl: string): AccountApi {
return new AccountApi(apiUrl);
}