Fixes check allowing preloading in local (unmanaged) mode

* adds apiEndpoint empty string check

Change-type: patch
This commit is contained in:
ab77 2020-10-16 15:19:22 -07:00
parent 2a8c1bdfe2
commit 0fd9b63762
No known key found for this signature in database
GPG Key ID: D094F44E5E29445A

View File

@ -467,7 +467,7 @@ export async function setTarget(target: TargetState, localSource?: boolean) {
await config.set({ name: target.local.name }, trx);
await deviceConfig.setTarget(target.local.config, trx);
if (localSource || apiEndpoint == null) {
if (localSource || apiEndpoint == null || apiEndpoint === '') {
await applicationManager.setTarget(
target.local.apps,
target.dependent,