e10-data 0.1.5 → 0.1.6
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/bin/e10-data.mjs +2 -1
- package/package.json +1 -1
package/bin/e10-data.mjs
CHANGED
|
@@ -1001,8 +1001,8 @@ async function expLock(args, json) {
|
|
|
1001
1001
|
printExpData(r, "有效锁");
|
|
1002
1002
|
return;
|
|
1003
1003
|
}
|
|
1004
|
-
const token = need("lock-token", args);
|
|
1005
1004
|
if (act === "heartbeat") {
|
|
1005
|
+
const token = need("lock-token", args);
|
|
1006
1006
|
const r = await postJson("/api/dw/expert-repository/v1/repositories/locks/heartbeat?lockToken=" + encodeURIComponent(token), {});
|
|
1007
1007
|
if (json) return r;
|
|
1008
1008
|
if (!expOk(r)) throw new Error(expFailMsg(r));
|
|
@@ -1010,6 +1010,7 @@ async function expLock(args, json) {
|
|
|
1010
1010
|
return;
|
|
1011
1011
|
}
|
|
1012
1012
|
if (act === "release") {
|
|
1013
|
+
const token = need("lock-token", args);
|
|
1013
1014
|
const req = new Request(BASE + "/api/dw/expert-repository/v1/repositories/locks?lockToken=" + encodeURIComponent(token), { method: "DELETE" });
|
|
1014
1015
|
const resp = await fetch(req, { headers: { "cookie": auth.cookie, "eteamsid": auth.eteamsid, "accept": "application/json" } });
|
|
1015
1016
|
const text = await resp.text();
|
package/package.json
CHANGED