mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Merge remote-tracking branch 'upstream/master' into no-limits
This commit is contained in:
commit
d9c9a05b09
101 changed files with 2998 additions and 2752 deletions
|
@ -20,6 +20,14 @@ define(['appStorage', 'events'], function (appStorage, events) {
|
|||
return this.get('enableAutoLogin') !== 'false';
|
||||
};
|
||||
|
||||
AppSettings.prototype.enableSystemExternalPlayers = function (val) {
|
||||
if (val !== null) {
|
||||
this.set('enableSystemExternalPlayers', val.toString());
|
||||
}
|
||||
|
||||
return this.get('enableSystemExternalPlayers') === 'true';
|
||||
};
|
||||
|
||||
AppSettings.prototype.enableAutomaticBitrateDetection = function (isInNetwork, mediaType, val) {
|
||||
var key = 'enableautobitratebitrate-' + mediaType + '-' + isInNetwork;
|
||||
if (val != null) {
|
||||
|
@ -123,13 +131,5 @@ define(['appStorage', 'events'], function (appStorage, events) {
|
|||
return appStorage.getItem(getKey(name, userId));
|
||||
};
|
||||
|
||||
AppSettings.prototype.enableSystemExternalPlayers = function (val) {
|
||||
if (val != null) {
|
||||
this.set('enableSystemExternalPlayers', val.toString());
|
||||
}
|
||||
|
||||
return this.get('enableSystemExternalPlayers') === 'true';
|
||||
};
|
||||
|
||||
return new AppSettings();
|
||||
});
|
||||
|
|
15
src/scripts/settings/webSettings.js
Normal file
15
src/scripts/settings/webSettings.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
let data;
|
||||
|
||||
function getConfig() {
|
||||
if (data) return Promise.resolve(data);
|
||||
return fetch("/config.json?nocache=" + new Date().getUTCMilliseconds()).then(function (response) {
|
||||
data = response.json();
|
||||
return data;
|
||||
});
|
||||
}
|
||||
|
||||
export function enableMultiServer() {
|
||||
return getConfig().then(config => {
|
||||
return config.multiserver;
|
||||
});
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue