upgrade all urls to https
This commit is contained in:
parent
6349166dbe
commit
fecbfaaf10
|
@ -73,7 +73,8 @@ const htmlSources = [
|
||||||
'views/*.ejs',
|
'views/*.ejs',
|
||||||
];
|
];
|
||||||
gulp.task('compress_html', () => {
|
gulp.task('compress_html', () => {
|
||||||
const { version } = JSON.parse(fs.readFileSync('./package.json'));
|
// eslint-disable-next-line global-require
|
||||||
|
const { version } = require('../package.json');
|
||||||
return gulp.src(htmlSources)
|
return gulp.src(htmlSources)
|
||||||
.pipe(ejs({
|
.pipe(ejs({
|
||||||
production: version,
|
production: version,
|
||||||
|
|
1548
package-lock.json
generated
1548
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -256,6 +256,8 @@ const utils = (() => {
|
||||||
let corsUrl = _url;
|
let corsUrl = _url;
|
||||||
if (params.cors === true) corsUrl = rewriteUrl(_url);
|
if (params.cors === true) corsUrl = rewriteUrl(_url);
|
||||||
const url = new URL(corsUrl);
|
const url = new URL(corsUrl);
|
||||||
|
// force url to secure
|
||||||
|
url.protocol = 'https:';
|
||||||
// add parameters if necessary
|
// add parameters if necessary
|
||||||
if (params.data) {
|
if (params.data) {
|
||||||
Object.keys(params.data).forEach((key) => {
|
Object.keys(params.data).forEach((key) => {
|
||||||
|
|
Loading…
Reference in a new issue