pinokiod 3.15.1 → 3.15.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/kernel/bin/caddy.js +17 -13
- package/package.json +1 -1
package/kernel/bin/caddy.js
CHANGED
|
@@ -103,21 +103,25 @@ class Caddy {
|
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
async installed() {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
if (
|
|
116
|
-
|
|
106
|
+
try {
|
|
107
|
+
let version = this.kernel.bin.installed.conda_versions.caddy
|
|
108
|
+
let coerced = semver.coerce(version)
|
|
109
|
+
let requirement = "<2.10.0"
|
|
110
|
+
let satisfied = semver.satisfies(coerced, requirement)
|
|
111
|
+
if (!satisfied) {
|
|
112
|
+
return false
|
|
113
|
+
}
|
|
114
|
+
let e = await this.kernel.exists(this.kernel.path("cache/XDG_DATA_HOME/caddy/pki/authorities/local/root.crt"))
|
|
115
|
+
if (e) {
|
|
116
|
+
if (this.kernel.platform === "win32") {
|
|
117
|
+
return this.kernel.bin.installed.conda.has("caddy")
|
|
118
|
+
} else {
|
|
119
|
+
return this.kernel.bin.installed.conda.has("caddy") && this.kernel.bin.installed.conda.has("nss")
|
|
120
|
+
}
|
|
117
121
|
} else {
|
|
118
|
-
return
|
|
122
|
+
return false
|
|
119
123
|
}
|
|
120
|
-
}
|
|
124
|
+
} catch (e) {
|
|
121
125
|
return false
|
|
122
126
|
}
|
|
123
127
|
}
|