';
- if (!options.pathReadOnly && systemInfo.OperatingSystem) {
+ if (!options.pathReadOnly && (options.instruction || systemInfo.OperatingSystem)) {
const instruction = options.instruction ? `${escapeHtml(options.instruction)}
` : '';
html += '
';
html += instruction;
From 13c49d514465ee3fc65eb5a1219037c64f3fc8ed Mon Sep 17 00:00:00 2001
From: viown <48097677+viown@users.noreply.github.com>
Date: Thu, 3 Oct 2024 07:59:27 +0300
Subject: [PATCH 3/4] Remove systemInfo from directory browser
---
.../directorybrowser/directorybrowser.js | 33 +++----------------
src/strings/en-us.json | 2 --
2 files changed, 5 insertions(+), 30 deletions(-)
diff --git a/src/components/directorybrowser/directorybrowser.js b/src/components/directorybrowser/directorybrowser.js
index 36b2207eb..4229f052e 100644
--- a/src/components/directorybrowser/directorybrowser.js
+++ b/src/components/directorybrowser/directorybrowser.js
@@ -11,15 +11,6 @@ import '../formdialog.scss';
import '../../elements/emby-button/emby-button';
import alert from '../alert';
-function getSystemInfo() {
- return systemInfo ? Promise.resolve(systemInfo) : ApiClient.getPublicSystemInfo().then(
- info => {
- systemInfo = info;
- return info;
- }
- );
-}
-
function onDialogClosed() {
loading.hide();
}
@@ -83,25 +74,14 @@ function getItem(cssClass, type, path, name) {
return html;
}
-function getEditorHtml(options, systemInfo) {
+function getEditorHtml(options) {
let html = '';
html += '
';
html += '
';
- if (!options.pathReadOnly && (options.instruction || systemInfo.OperatingSystem)) {
+ if (!options.pathReadOnly && options.instruction) {
const instruction = options.instruction ? `${escapeHtml(options.instruction)}
` : '';
html += '
';
html += instruction;
- if (systemInfo.OperatingSystem.toLowerCase() === 'bsd') {
- html += '
';
- html += '
';
- html += globalize.translate('MessageDirectoryPickerBSDInstruction');
- html += '
';
- } else if (systemInfo.OperatingSystem.toLowerCase() === 'linux') {
- html += '
';
- html += '
';
- html += globalize.translate('MessageDirectoryPickerLinuxInstruction');
- html += '
';
- }
html += '
';
}
html += '
';
- html += getEditorHtml(options, fetchedSystemInfo);
+ html += getEditorHtml(options);
dlg.innerHTML = html;
initEditor(dlg, options, fileOptions);
dlg.addEventListener('close', onDialogClosed);
diff --git a/src/strings/en-us.json b/src/strings/en-us.json
index 28fbf0b55..9a70c6b77 100644
--- a/src/strings/en-us.json
+++ b/src/strings/en-us.json
@@ -1144,8 +1144,6 @@
"MessageContactAdminToResetPassword": "Please contact your system administrator to reset your password.",
"MessageCreateAccountAt": "Create an account at {0}",
"MessageDeleteTaskTrigger": "Are you sure you wish to delete this task trigger?",
- "MessageDirectoryPickerBSDInstruction": "For BSD, you may need to set up storage within your 'FreeNAS Jail' so Jellyfin can access your media.",
- "MessageDirectoryPickerLinuxInstruction": "For Linux on Arch Linux, CentOS, Debian, Fedora, openSUSE, or Ubuntu, you must grant the service user at least read access to your storage locations.",
"MessageDownloadQueued": "Download queued.",
"MessageEnablingOptionLongerScans": "Enabling this option may result in significantly longer library scans.",
"MessageFileReadError": "There was an error reading the file. Please try again.",
From abcc625b60a3adb91e775f56b9915c4091113352 Mon Sep 17 00:00:00 2001
From: viown <48097677+viown@users.noreply.github.com>
Date: Wed, 19 Nov 2025 20:56:45 +0300
Subject: [PATCH 4/4] Remove redundant check
---
src/components/directorybrowser/directorybrowser.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/components/directorybrowser/directorybrowser.js b/src/components/directorybrowser/directorybrowser.js
index 4229f052e..6e0bb11bf 100644
--- a/src/components/directorybrowser/directorybrowser.js
+++ b/src/components/directorybrowser/directorybrowser.js
@@ -79,7 +79,7 @@ function getEditorHtml(options) {
html += '
';
html += '
';
if (!options.pathReadOnly && options.instruction) {
- const instruction = options.instruction ? `${escapeHtml(options.instruction)}
` : '';
+ const instruction = `${escapeHtml(options.instruction)}
`;
html += '
';
html += instruction;
html += '
';