]>
Commit | Line | Data |
---|---|---|
fd8710b8 C |
1 | import { exists } from './misc' |
2 | import { LogLevel } from '../../../shared/models/server/log-level.type' | |
3 | ||
4 | const logLevels: LogLevel[] = [ 'debug', 'info', 'warn', 'error' ] | |
5 | ||
6 | function isValidLogLevel (value: any) { | |
bdd428a6 | 7 | return exists(value) && logLevels.includes(value) |
fd8710b8 C |
8 | } |
9 | ||
10 | // --------------------------------------------------------------------------- | |
11 | ||
12 | export { | |
13 | isValidLogLevel | |
14 | } |