refactor folders to move "/state" (IApplicationState) inside "/context" (IApplicationContext)

This commit is contained in:
undergroundwires
2020-12-28 22:11:23 +01:00
parent f7557bcc0f
commit 34672414c3
64 changed files with 106 additions and 107 deletions

View File

@@ -0,0 +1,14 @@
import { BaseEntity } from '@/infrastructure/Entity/BaseEntity';
import { IScript } from '@/domain/IScript';
export class SelectedScript extends BaseEntity<string> {
constructor(
public readonly script: IScript,
public readonly revert: boolean,
) {
super(script.id);
if (revert && !script.canRevert()) {
throw new Error('cannot revert an irreversible script');
}
}
}