18 lines
334 B
JavaScript
18 lines
334 B
JavaScript
export function isBetweenVersions(min, target, max) {
|
|
|
|
if (min) {
|
|
const isOlderThanMin = foundry.utils.isNewerVersion(min, target);
|
|
if (isOlderThanMin) {
|
|
return false;
|
|
};
|
|
};
|
|
|
|
if (max) {
|
|
const isNewerThanMax = foundry.utils.isNewerVersion(target, max);
|
|
if (isNewerThanMax) {
|
|
return false;
|
|
};
|
|
};
|
|
|
|
return true;
|
|
};
|