n8n/packages/workflow/src/GlobalState.ts
2023-10-27 14:17:52 +02:00

16 lines
316 B
TypeScript

import { deepCopy } from './utils';
export interface GlobalState {
defaultTimezone: string;
}
let globalState: GlobalState = { defaultTimezone: 'America/New_York' };
export function setGlobalState(state: GlobalState) {
globalState = state;
}
export function getGlobalState() {
return deepCopy(globalState);
}