Skip to content

Commit

Permalink
Merge pull request #3247 from thornbill/remove-network-library
Browse files Browse the repository at this point in the history
Remove network device option from add library dialog
  • Loading branch information
thornbill committed Dec 29, 2021
2 parents 4e3e91f + c41c566 commit a9dd511
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
16 changes: 4 additions & 12 deletions src/components/directorybrowser/directorybrowser.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,11 @@ function refreshDirectoryBrowser(page, path, fileOptions, updatePathOnError) {

const promises = [];

if (path === 'Network') {
promises.push(ApiClient.getNetworkDevices());
if (path) {
promises.push(ApiClient.getDirectoryContents(path, fileOptions));
promises.push(ApiClient.getParentPath(path));
} else {
if (path) {
promises.push(ApiClient.getDirectoryContents(path, fileOptions));
promises.push(ApiClient.getParentPath(path));
} else {
promises.push(ApiClient.getDrives());
}
promises.push(ApiClient.getDrives());
}

Promise.all(promises).then(
Expand All @@ -61,10 +57,6 @@ function refreshDirectoryBrowser(page, path, fileOptions, updatePathOnError) {
html += getItem(cssClass, folder.Type, folder.Path, folder.Name);
}

if (!path) {
html += getItem('lnkPath lnkDirectory', '', 'Network', globalize.translate('ButtonNetwork'));
}

page.querySelector('.results').innerHTML = html;
loading.hide();
}, () => {
Expand Down
1 change: 0 additions & 1 deletion src/strings/en-us.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@
"ButtonLibraryAccess": "Library access",
"ButtonManualLogin": "Manual Login",
"ButtonMore": "More",
"ButtonNetwork": "Network",
"ButtonNextTrack": "Next track",
"ButtonOk": "Ok",
"ButtonOpen": "Open",
Expand Down

0 comments on commit a9dd511

Please sign in to comment.