diff --git a/shared/utils.ts b/shared/utils.ts index 9e99651..0df594c 100644 --- a/shared/utils.ts +++ b/shared/utils.ts @@ -3,21 +3,6 @@ export const pickRandom = (arr: T[]) => { return arr[index]; }; -function bashHashStr(str: string) { - let hash = 5381, - i = str.length; - - while (i) { - hash = (hash * 33) ^ str.charCodeAt(--i); - } - - return hash >>> 0; -} - -export const hashStr = (str: string) => { - return Number(`0.${bashHashStr(str)}`); -}; - export const weightedPickRandom = ( arr: T[], getWeight: (item: T) => number = () => 1,