feat: convert UdevRulesInfo to string enum (#921)

* feat: convert UdevRulesInfo to string enum

For easier log reading better to use string enum.

* fix typo
This commit is contained in:
Róbert Kiss
2019-02-24 22:04:46 +01:00
committed by László Monda
parent 3a1451a6a9
commit f94b221ee9
3 changed files with 6 additions and 6 deletions

View File

@@ -3,14 +3,14 @@
* Only on Linux need extra udev rules.
*/
export enum UdevRulesInfo {
Unkonwn,
Ok,
Unknown = 'Unknown',
Ok = 'Ok',
/**
* Udev rules not exists need to setup on Linux
*/
NeedToSetup,
NeedToSetup = 'NeedToSetup',
/**
* Udev rules exist but different than expected on Linux
*/
Different
Different = 'Different'
}

View File

@@ -31,7 +31,7 @@ export class UhkHidDevice {
private _prevDevices = [];
private _device: HID;
private _hasPermission = false;
private _udevRulesInfo = UdevRulesInfo.Unkonwn;
private _udevRulesInfo = UdevRulesInfo.Unknown;
constructor(private logService: LogService,
private options: CommandLineArgs,

View File

@@ -31,7 +31,7 @@ export const initialState: State = {
hasPermission: true,
bootloaderActive: false,
zeroInterfaceAvailable: true,
udevRuleInfo: UdevRulesInfo.Unkonwn,
udevRuleInfo: UdevRulesInfo.Unknown,
saveToKeyboard: initProgressButtonState,
savingToKeyboard: false,
updatingFirmware: false,