mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-15 12:20:31 +00:00
5 lines
192 B
TypeScript
5 lines
192 B
TypeScript
export function sanitizeDatabaseName(dbName: string) {
|
|
// Replace any character that is not alphanumeric or an underscore with an underscore
|
|
return dbName.replace(/[^a-zA-Z0-9_]/g, '');
|
|
}
|