Replace http with https
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
4b9b29fc94
commit
9bbf43c590
|
@ -50,8 +50,9 @@ module.exports = Self => {
|
|||
const fileName = srcFile.replace(/\.|\/|:|\?|\\|=|%/g, '');
|
||||
const file = `${fileName}.png`;
|
||||
const filePath = path.join(tempPath, file);
|
||||
const imageUrl = image.url.replace('http://', 'https://');
|
||||
|
||||
https.get(image.url, async response => {
|
||||
https.get(imageUrl, async response => {
|
||||
if (response.statusCode != 200) {
|
||||
const error = new Error(`Could not download the image. Status code ${response.statusCode}`);
|
||||
|
||||
|
|
Loading…
Reference in New Issue