Fix send email error when empty connected account (#10005)
- Fix send email error when empty connected account - Add a global util to valid uuid - Add an util to check if object is workflow related
This commit is contained in:
@ -1,11 +0,0 @@
|
||||
import { isValidUuid } from '~/utils/isValidUuid';
|
||||
|
||||
describe('isValidUuid', () => {
|
||||
it('returns true if value is a valid UUID', () => {
|
||||
expect(isValidUuid('bec09e27-4ecc-4a85-afc1-f2c0ace28bfa')).toBe(true);
|
||||
});
|
||||
|
||||
it('returns false if value is not a valid UUID', () => {
|
||||
expect(isValidUuid('123e4567-e89b-12d3-a456-42661417400')).toBe(false);
|
||||
});
|
||||
});
|
||||
@ -1,5 +0,0 @@
|
||||
export const isValidUuid = (value: string) => {
|
||||
return /^[0-9A-F]{8}-[0-9A-F]{4}-[4][0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i.test(
|
||||
value,
|
||||
);
|
||||
};
|
||||
Reference in New Issue
Block a user