feat(core): Allow transferring workflows from any project to any team project (#9534)
This commit is contained in:
@@ -1,6 +1,16 @@
|
||||
import { ResponseError } from './abstract/response.error';
|
||||
|
||||
export class NotFoundError extends ResponseError {
|
||||
static isDefinedAndNotNull<T>(
|
||||
value: T | undefined | null,
|
||||
message: string,
|
||||
hint?: string,
|
||||
): asserts value is T {
|
||||
if (value === undefined || value === null) {
|
||||
throw new NotFoundError(message, hint);
|
||||
}
|
||||
}
|
||||
|
||||
constructor(message: string, hint: string | undefined = undefined) {
|
||||
super(message, 404, 404, hint);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
import { ResponseError } from './abstract/response.error';
|
||||
|
||||
export class TransferWorkflowError extends ResponseError {
|
||||
constructor(message: string) {
|
||||
super(message, 400, 400);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user