move ffmpeg code to its own file, rename types folder to lib
This commit is contained in:
parent
f322b45ee1
commit
6d779e7811
13 changed files with 310 additions and 253 deletions
|
@ -1,26 +0,0 @@
|
|||
/* eslint-disable @typescript-eslint/no-namespace */
|
||||
declare global {
|
||||
namespace Express {
|
||||
interface User {
|
||||
id? : number | string,
|
||||
username: string,
|
||||
hashed_password?: any,
|
||||
salt?: any
|
||||
}
|
||||
}
|
||||
}
|
||||
/**Splits a file name into its name and then its extension */
|
||||
export function extension(str: string){
|
||||
const file = str.split("/").pop();
|
||||
return [file.substr(0,file.lastIndexOf(".")),file.substr(file.lastIndexOf("."),file.length).toLowerCase()];
|
||||
}
|
||||
/**Type for user data */
|
||||
export interface User {
|
||||
id? : number | string,
|
||||
username: string,
|
||||
hashed_password?: any,
|
||||
salt?: any
|
||||
}
|
||||
|
||||
export const videoExtensions = [".mp4", ".mov", ".avi", ".flv", ".mkv", ".wmv", ".webm"];
|
||||
export const imageExtensions = [".jpg", ".jpeg", ".png", ".gif", ".bmp", ".svg", ".tiff", ".webp"];
|
Loading…
Add table
Add a link
Reference in a new issue