Skip to content

Commit

Permalink
sdk: fix StorageSettings 'device' defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
koush committed Mar 6, 2023
1 parent bb9f3d5 commit d01c0fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sdk/src/storage-settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ function parseValue(value: string, setting: StorageSetting, readDefaultValue: ()
if (type === 'device') {
if (rawDevice)
return value;
return systemManager.getDeviceById(value);
return systemManager.getDeviceById(value) || systemManager.getDeviceById(readDefaultValue());
}

// string type, so check if it is json.
Expand Down

0 comments on commit d01c0fa

Please sign in to comment.