Buildout 3.59.1; Fixing preconfiguration loader
This commit is contained in:
@ -147972,37 +147972,46 @@ var App = /*#__PURE__*/function (_React$Component) {
|
||||
var message = _hint$originalExcepti.message; // Filter out issues that destroy our quota and that are not informative enough to
|
||||
// actually resolve.
|
||||
|
||||
if (message && (message.match(/Websocket/i) || message.match(/NotSupportedError/i) || message.match(/Non-Error promise rejection captured with keys: call, message, value/i) || message.match(/Cannot read property 'addChunk' of undefined/i))) {
|
||||
if (message && (message.match(/Websocket/i) || message.match(/NotSupportedError/i) || message.match(/NotSupportedError: The element has no supported sources./i) || message.match(/Non-Error promise rejection captured with keys: call, message, value/i) || message.match(/Cannot read property 'addChunk' of undefined/i))) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return event;
|
||||
}
|
||||
});
|
||||
} // Load query param settings
|
||||
} // Accept incoming preconfiguration via URL parameters and inject into application state.
|
||||
// For example: iris?snapcast={"enabled":true,"host":"myserver.local"}
|
||||
|
||||
|
||||
var configs = ['ui', 'spotify', 'pusher', 'snapcast', 'mopidy', 'google', 'lastfm', 'genius'];
|
||||
var params = new URLSearchParams(window.location.search);
|
||||
var changed = [];
|
||||
var urlParams = params.forEach(function (v, k) {
|
||||
if (!configs.includes(k)) return;
|
||||
|
||||
try {
|
||||
_util_storage__WEBPACK_IMPORTED_MODULE_51__["default"].set(k, JSON.parse(v));
|
||||
changed.push(k);
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
});
|
||||
if (params) {
|
||||
params.forEach(function (value, key) {
|
||||
try {
|
||||
var json = JSON.parse(value);
|
||||
|
||||
if (changed.length > 0) {
|
||||
changed.forEach(function (k) {
|
||||
return params["delete"](k);
|
||||
switch (key) {
|
||||
case 'ui':
|
||||
case 'spotify':
|
||||
case 'pusher':
|
||||
case 'snapcast':
|
||||
case 'mopidy':
|
||||
_this.props["".concat(key, "Actions")].set(json);
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
} catch (e) {
|
||||
console.error('Preconfiguration failed', {
|
||||
e: e,
|
||||
key: key,
|
||||
value: value
|
||||
});
|
||||
return;
|
||||
}
|
||||
});
|
||||
var url = window.location.toString().replace(window.location.search, params.toString());
|
||||
console.log("Settings changed, redirecting to ".concat(url), changed);
|
||||
window.location.assign(url);
|
||||
}
|
||||
|
||||
_this.handleInstallPrompt = _this.handleInstallPrompt.bind(_assertThisInitialized(_this));
|
||||
@ -169754,11 +169763,12 @@ function reducer() {
|
||||
/*!*******************************************!*\
|
||||
!*** ./src/js/services/pusher/actions.js ***!
|
||||
\*******************************************/
|
||||
/*! exports provided: setPort, setUsername, connect, disconnect, upgrade, reload, restart, localScan, getConnections, connectionAdded, updateConnection, connectionChanged, connectionRemoved, request, getConfig, getVersion, deliverBroadcast, deliverMessage, getRadio, startRadio, updateRadio, stopRadio, radioStarted, radioChanged, radioStopped, debug, getQueueMetadata, queueMetadataChanged, addQueueMetadata, getPinned, addPinned, removePinned, setPinned, pinnedUpdated, getCommands, setCommand, setCommands, removeCommand, runCommand, commandsUpdated */
|
||||
/*! exports provided: set, setPort, setUsername, connect, disconnect, upgrade, reload, restart, localScan, getConnections, connectionAdded, updateConnection, connectionChanged, connectionRemoved, request, getConfig, getVersion, deliverBroadcast, deliverMessage, getRadio, startRadio, updateRadio, stopRadio, radioStarted, radioChanged, radioStopped, debug, getQueueMetadata, queueMetadataChanged, addQueueMetadata, getPinned, addPinned, removePinned, setPinned, pinnedUpdated, getCommands, setCommand, setCommands, removeCommand, runCommand, commandsUpdated */
|
||||
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||||
|
||||
"use strict";
|
||||
__webpack_require__.r(__webpack_exports__);
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "set", function() { return set; });
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setPort", function() { return setPort; });
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "setUsername", function() { return setUsername; });
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "connect", function() { return connect; });
|
||||
@ -169799,6 +169809,12 @@ __webpack_require__.r(__webpack_exports__);
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "removeCommand", function() { return removeCommand; });
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "runCommand", function() { return runCommand; });
|
||||
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "commandsUpdated", function() { return commandsUpdated; });
|
||||
function set(data) {
|
||||
return {
|
||||
type: 'PUSHER_SET',
|
||||
data: data
|
||||
};
|
||||
}
|
||||
function setPort(port) {
|
||||
return {
|
||||
type: 'PUSHER_SET_PORT',
|
||||
@ -170945,6 +170961,9 @@ function reducer() {
|
||||
connecting: false
|
||||
});
|
||||
|
||||
case 'PUSHER_SET':
|
||||
return _objectSpread(_objectSpread({}, pusher), action.data);
|
||||
|
||||
case 'PUSHER_SET_PORT':
|
||||
return _objectSpread(_objectSpread({}, pusher), {}, {
|
||||
port: action.port
|
||||
|
||||
File diff suppressed because one or more lines are too long
4
mopidy_iris/static/app.min.js
vendored
4
mopidy_iris/static/app.min.js
vendored
File diff suppressed because one or more lines are too long
@ -115,8 +115,8 @@
|
||||
|
||||
// Release details
|
||||
// These are automatically injected to built HTML
|
||||
var build = "1633136375";
|
||||
var version = "3.58.2";
|
||||
var build = "1633159406";
|
||||
var version = "3.59.1";
|
||||
|
||||
// Construct the script tag
|
||||
var js = document.createElement("script");
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
{
|
||||
"manifest_version": "3.58.2",
|
||||
"manifest_version": "3.59.1",
|
||||
"short_name": "Iris",
|
||||
"name": "Iris",
|
||||
"icons": [
|
||||
|
||||
Reference in New Issue
Block a user