mirror of
https://github.com/OpenSquawk/OpenSquawk
synced 2026-08-01 06:06:05 +08:00
Point bridge download to GitHub
This commit is contained in:
14
server/utils/bridge.ts
Normal file
14
server/utils/bridge.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
export function normalizeBridgeToken(input: unknown) {
|
||||
if (typeof input !== 'string') {
|
||||
return null
|
||||
}
|
||||
const token = input.trim()
|
||||
if (!token) {
|
||||
return null
|
||||
}
|
||||
if (token.length < 8 || token.length > 256) {
|
||||
return null
|
||||
}
|
||||
return token
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user