1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-11-24 20:06:55 +01:00

Chore: update interface (and make it a type)

This commit is contained in:
Thomas Heartman 2024-01-11 18:31:17 +05:30
parent 270520e7fc
commit 9b3dc328ad
No known key found for this signature in database
GPG Key ID: BD1F880DAED1EE78

View File

@ -21,11 +21,22 @@ export interface IChangeRequest {
schedule?: IChangeRequestSchedule; schedule?: IChangeRequestSchedule;
} }
export interface IChangeRequestSchedule { export type IChangeRequestSchedule =
scheduledAt: string; | {
status: 'pending' | 'failed'; status: 'pending';
failureReason?: string; scheduledAt: string;
} }
| {
status: 'failed';
scheduledAt: string;
failureReason?: string | null;
reason: string;
}
| {
status: 'suspended';
scheduledAt: string;
reason: string;
};
export interface IChangeRequestEnvironmentConfig { export interface IChangeRequestEnvironmentConfig {
environment: string; environment: string;