mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-27 07:52:24 +00:00
12 lines
285 B
JavaScript
12 lines
285 B
JavaScript
export function normalizeHexString(value) {
|
|
if (typeof value !== "string") {
|
|
return "";
|
|
}
|
|
|
|
const trimmed = value.trim();
|
|
return trimmed ? trimmed.toLowerCase() : "";
|
|
}
|
|
|
|
export const normalizeHexId = normalizeHexString;
|
|
export const normalizeHexPubkey = normalizeHexString;
|