mirror of
https://codeberg.org/timelimit/timelimit-server.git
synced 2026-08-31 19:03:45 +02:00
Make mail code verification less strict
This commit is contained in:
@@ -31,3 +31,13 @@ export const randomWords = (numberOfWords: number) => (
|
||||
.map((item) => randomWord())
|
||||
.join(' ')
|
||||
)
|
||||
|
||||
const preprocessStringForComparing = (input: string) => (
|
||||
input
|
||||
.replace(/ |\*/g, '')
|
||||
.toLowerCase()
|
||||
)
|
||||
|
||||
export const areWordSequencesEqual = (a: string, b: string) => (
|
||||
preprocessStringForComparing(a) === preprocessStringForComparing(b)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user