Fixes url escaping (#24)

This commit is contained in:
Pedro Lamas
2021-02-04 07:51:46 +00:00
committed by GitHub
parent 22f832fbad
commit 8e17765e3f
2 changed files with 2 additions and 2 deletions

View File

@@ -748,7 +748,7 @@
"manufacturerCode": 4687,
"imageType": 0,
"modelId": "GL-S-007P",
"url": "https://github.com/Koenkk/zigbee-OTA/raw/master/images/Gledopto/GL-S-007P_V15_A1_OTAV5_20210201_90%.ota",
"url": "https://github.com/Koenkk/zigbee-OTA/raw/master/images/Gledopto/GL-S-007P_V15_A1_OTAV5_20210201_90%25.ota",
"path": "images/Gledopto/GL-S-007P_V15_A1_OTAV5_20210201_90%.ota"
}
]

View File

@@ -80,7 +80,7 @@ const main = async () => {
entry.url = filenameOrURL;
} else {
const destinationPosix = destination.replace(/\\/g, '/');
entry.url = `${baseURL}/${destinationPosix}`;
entry.url = `${baseURL}/${escape(destinationPosix)}`;
entry.path = destinationPosix;
}