fix: image meta

This commit is contained in:
2024-01-08 12:23:12 +00:00
parent 84bda4e33d
commit 30b21cfe91
4 changed files with 22 additions and 18 deletions

View File

@ -462,7 +462,8 @@ export function kvToObject<T>(o: string, sep?: string) {
export function defaultAvatar(input?: string) {
if (isOffline()) return Nostrich;
return `https://robohash.v0l.io/${input ?? "missing"}.png${isHalloween() ? "?set=set2" : ""}`;
const key = (input?.length ?? 0) === 0 ? "missing" : input;
return `https://robohash.v0l.io/${key}.png${isHalloween() ? "?set=set2" : ""}`;
}
export function isFormElement(target: HTMLElement): boolean {