fix: board crashes with empty string favicon (#2192)

This commit is contained in:
Meier Lukas
2025-01-30 20:15:05 +01:00
committed by GitHub
parent c05c51856b
commit bd0b7c9518
2 changed files with 10 additions and 3 deletions

View File

@@ -1,3 +1,7 @@
export const capitalize = <T extends string>(str: T) => {
return (str.charAt(0).toUpperCase() + str.slice(1)) as Capitalize<T>;
};
export const isNullOrWhitespace = (value: string | null): value is null => {
return value == null || value.trim() === "";
};