Browse Source
Merge pull request #207 from nojronatron/155-bugfix-adc-mult-override
change validation type to IsNumber
pull/233/head
Ben Meadors
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
2 additions and
2 deletions
-
src/validation/config/power.ts
|
|
|
@ -1,6 +1,6 @@ |
|
|
|
import type { Message } from "@bufbuild/protobuf"; |
|
|
|
import type { Protobuf } from "@meshtastic/js"; |
|
|
|
import { IsBoolean, IsInt, Max, Min } from "class-validator"; |
|
|
|
import { IsBoolean, IsInt, IsNumber, Max, Min } from "class-validator"; |
|
|
|
|
|
|
|
export class PowerValidation |
|
|
|
implements Omit<Protobuf.Config.Config_PowerConfig, keyof Message> |
|
|
|
@ -11,7 +11,7 @@ export class PowerValidation |
|
|
|
@IsInt() |
|
|
|
onBatteryShutdownAfterSecs: number; |
|
|
|
|
|
|
|
@IsInt() |
|
|
|
@IsNumber() |
|
|
|
@Min(2) |
|
|
|
@Max(4) |
|
|
|
adcMultiplierOverride: number; |
|
|
|
|