Fix: Uncaught SyntaxError: Identifier 'getCorsUrl' has already been declared (#3204)

Issue #3202 

move shared modules/default/utils.js file to index.html
This commit is contained in:
Bugsounet - Cédric 2023-09-19 07:14:11 +02:00 committed by GitHub
parent e5adbea49c
commit af0fe37f70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 2 deletions

View File

@ -47,6 +47,7 @@ _This release is scheduled to be released on 2023-10-01._
- Fix ipWhiteList test (#3179) - Fix ipWhiteList test (#3179)
- Fix newsfeed: Convert HTML entities, codes and tag in description (#3191) - Fix newsfeed: Convert HTML entities, codes and tag in description (#3191)
- Respect width/height (no fullscreen) if set in electronOptions (together with `fullscreen: false`) in `config.js` (#3174) - Respect width/height (no fullscreen) if set in electronOptions (together with `fullscreen: false`) in `config.js` (#3174)
- Fix `Uncaught SyntaxError: Identifier 'getCorsUrl' has already been declared (at utils.js:1:1)` when using `clock` and `weather` module (#3204)
## [2.24.0] - 2023-07-01 ## [2.24.0] - 2023-07-01

View File

@ -46,6 +46,7 @@
<script type="text/javascript" src="#CONFIG_FILE#"></script> <script type="text/javascript" src="#CONFIG_FILE#"></script>
<script type="text/javascript" src="vendor/vendor.js"></script> <script type="text/javascript" src="vendor/vendor.js"></script>
<script type="text/javascript" src="modules/default/defaultmodules.js"></script> <script type="text/javascript" src="modules/default/defaultmodules.js"></script>
<script type="text/javascript" src="modules/default/utils.js"></script>
<script type="text/javascript" src="js/logger.js"></script> <script type="text/javascript" src="js/logger.js"></script>
<script type="text/javascript" src="translations/translations.js"></script> <script type="text/javascript" src="translations/translations.js"></script>
<script type="text/javascript" src="js/translator.js"></script> <script type="text/javascript" src="js/translator.js"></script>

View File

@ -38,7 +38,7 @@ Module.register("clock", {
}, },
// Define required scripts. // Define required scripts.
getScripts: function () { getScripts: function () {
return ["moment.js", "moment-timezone.js", "suncalc.js", this.file("../utils.js")]; return ["moment.js", "moment-timezone.js", "suncalc.js"];
}, },
// Define styles. // Define styles.
getStyles: function () { getStyles: function () {

View File

@ -62,7 +62,7 @@ Module.register("weather", {
// Return the scripts that are necessary for the weather module. // Return the scripts that are necessary for the weather module.
getScripts: function () { getScripts: function () {
return ["moment.js", this.file("../utils.js"), "weatherutils.js", "weatherobject.js", this.file("providers/overrideWrapper.js"), "weatherprovider.js", "suncalc.js", this.file(`providers/${this.config.weatherProvider.toLowerCase()}.js`)]; return ["moment.js", "weatherutils.js", "weatherobject.js", this.file("providers/overrideWrapper.js"), "weatherprovider.js", "suncalc.js", this.file(`providers/${this.config.weatherProvider.toLowerCase()}.js`)];
}, },
// Override getHeader method. // Override getHeader method.