Skip to content

Commit 6d2182d

Browse files
committed
take 2 on proxy
1 parent 5ef41da commit 6d2182d

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

src/kiri/app/export.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -248,14 +248,15 @@ function exportGCodeDialog(gcode, sections, info, names) {
248248
host = octo_host.value.toLowerCase(),
249249
apik = octo_apik.value,
250250
type = octo_type.value,
251-
secure = api.util.isSecure(host),
252-
proxy = !secure && api.feature.proxy ? host : undefined;
251+
targetLocal = !api.util.isSecure(host),
252+
siteSecure = api.const.SECURE,
253+
proxy = targetLocal && api.feature.proxy ? host : undefined;
253254

254255
if (host.indexOf("http") !== 0) {
255256
api.show.alert("host missing protocol (http:// or https://)");
256257
return;
257258
}
258-
if (api.const.SECURE && !secure && !proxy) {
259+
if (siteSecure && targetLocal && !proxy) {
259260
api.show.alert("host must begin with 'https' on a secure site");
260261
return;
261262
}

0 commit comments

Comments
 (0)