Remove uneeded database migrations (#6985)

This commit is contained in:
Daniel Espino García
2023-01-19 16:56:30 +01:00
committed by GitHub
parent 2597e06ac2
commit 9c19e4d04a
4 changed files with 4 additions and 60 deletions

View File

@@ -9,23 +9,6 @@ export async function getCSRFFromCookie(url: string) {
return cookies.MMCSRF?.value;
}
// This has been deprecated and is only used for migrations
export const hashCode_DEPRECATED = (str: string): string => {
let hash = 0;
let i;
let chr;
if (!str || str.length === 0) {
return hash.toString();
}
for (i = 0; i < str.length; i++) {
chr = str.charCodeAt(i);
hash = ((hash << 5) - hash) + chr;
hash |= 0; // Convert to 32bit integer
}
return hash.toString();
};
export const urlSafeBase64Encode = (str: string): string => {
return base64.encode(str).replace(/\+/g, '-').replace(/\//g, '_');
};