Rename flavours/glitch/util into flavours/glitch/utils

This commit is contained in:
Claire
2022-10-11 10:41:15 +02:00
parent 1be97ce17f
commit d3879c07b1
139 changed files with 139 additions and 139 deletions

View File

@@ -0,0 +1,5 @@
// This function returns the new value unless it is `null` or
// `undefined`, in which case it returns the old one.
export function overwrite (oldVal, newVal) {
return newVal === null || typeof newVal === 'undefined' ? oldVal : newVal;
}