fix(core): update
This commit is contained in:
@ -3,6 +3,6 @@ import * as plugins from './sdk.plugins';
|
||||
/**
|
||||
* AgEnvironment handles the provision of environment variables to handlers
|
||||
*/
|
||||
export class AgEnvironment {
|
||||
|
||||
export abstract class AgEnvironment {
|
||||
public abstract async getEnvVar(envVarName: string): Promise<string>;
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
import * as plugins from './sdk.plugins';
|
||||
import { AuthInfo } from './sdk.classes.authinfo';
|
||||
import { AgEnvironment } from './sdk.classes.agenvironment';
|
||||
|
||||
export interface IRequirementResult {
|
||||
allOk: boolean;
|
||||
@ -7,6 +8,8 @@ export interface IRequirementResult {
|
||||
}
|
||||
|
||||
export abstract class AAgHandler<TClaim> {
|
||||
public agEnvironment: AgEnvironment;
|
||||
|
||||
/**
|
||||
* a slug that separates the handler from other handlers
|
||||
*/
|
||||
@ -14,6 +17,10 @@ export abstract class AAgHandler<TClaim> {
|
||||
public abstract typedrouter: plugins.typedrequest.TypedRouter;
|
||||
public abstract checkRequirements(): Promise<IRequirementResult>;
|
||||
|
||||
constructor(agEnvironmentArg: AgEnvironment) {
|
||||
this.agEnvironment = agEnvironmentArg;
|
||||
};
|
||||
|
||||
/**
|
||||
* start the ag-handler
|
||||
*/
|
||||
|
Reference in New Issue
Block a user