Skip to content

Commit 2a2547a

Browse files
author
Pavlo Kulyk
committed
fix: update condition for default user notification in Sidebar component
1 parent 6c13157 commit 2a2547a

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

adminforth/modules/restApi.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -411,8 +411,7 @@ export default class AdminForthRestAPI implements IAdminForthRestAPI {
411411
globalInjections: this.adminforth.config.customization.globalInjections,
412412
userFullnameField: this.adminforth.config.auth.userFullNameField,
413413
settingPages: settingPages,
414-
defaultUserExists: defaultUserExists,
415-
isPrivateIP: isPrivateIP,
414+
hasDefaultUserOnPublicNetwork: defaultUserExists && !isPrivateIP
416415
}
417416

418417
// translate menu labels

adminforth/spa/src/components/Sidebar.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
</div>
5252
</div>
5353

54-
<div v-if="coreStore.config.defaultUserExists && !coreStore.config.isPrivateIP" class="p-4 mb-4 text-white rounded-lg bg-red-700/80 fill-white text-sm">
54+
<div v-if="coreStore.config.hasDefaultUserOnPublicNetwork" class="p-4 mb-4 text-white rounded-lg bg-red-700/80 fill-white text-sm">
5555
<IconExclamationCircleOutline class="inline-block align-text-bottom mr-0,5 w-5 h-5" />
5656
Default user <strong>"adminforth"</strong> detected. Delete it and create your own account.
5757
</div>

0 commit comments

Comments
 (0)