mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-08 17:03:53 +00:00
db0eee3b9c
* chore: upgrade dependencies * feat/mac: draft pipeline * feat/mac: use public folder for transient files * feat/mac: set app fullscreen * feat/mac: cmd + , toggles menu * feat/mac: update readme * refact: easier login process * refact prevent style issues with safari * refact reduce css download * style: cleanup paginator design * style: studio clock is responsive * style: fix spacing style issues with safari
14 lines
365 B
JavaScript
14 lines
365 B
JavaScript
/**
|
|
* @description Validates two time entries
|
|
* @param {number} timeStart
|
|
* @param {number} timeEnd
|
|
* @returns {{catch: string, value: boolean}}
|
|
*/
|
|
export const validateTimes = (timeStart, timeEnd) => {
|
|
const validate = { value: true, catch: '' };
|
|
if (timeStart > timeEnd) {
|
|
validate.catch = 'Start time later than end time';
|
|
}
|
|
return validate;
|
|
};
|