tutuca 0.9.96 → 0.9.97
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/dist/tutuca-cli.js +3 -2
- package/dist/tutuca-dev.ext.js +4 -2
- package/dist/tutuca-dev.js +4 -2
- package/dist/tutuca-dev.min.js +1 -1
- package/dist/tutuca-extra.ext.js +4 -2
- package/dist/tutuca-extra.js +4 -2
- package/dist/tutuca-extra.min.js +1 -1
- package/dist/tutuca.ext.js +4 -2
- package/dist/tutuca.js +4 -2
- package/dist/tutuca.min.js +1 -1
- package/package.json +1 -1
- package/skill/tutuca-source/tutuca.ext.js +4 -2
package/package.json
CHANGED
|
@@ -1224,6 +1224,8 @@ class RequestHandler {
|
|
|
1224
1224
|
import { isIndexed, isKeyed } from "immutable";
|
|
1225
1225
|
|
|
1226
1226
|
// src/cache.js
|
|
1227
|
+
var isWeakKey = (k) => k !== null && (typeof k === "object" || typeof k === "function");
|
|
1228
|
+
|
|
1227
1229
|
class NullDomCache {
|
|
1228
1230
|
get(_keys, _cacheKey) {}
|
|
1229
1231
|
set(_keys, _cacheKey, _v) {}
|
|
@@ -1267,7 +1269,7 @@ class WeakMapDomCache {
|
|
|
1267
1269
|
const key = keys[i];
|
|
1268
1270
|
let next = cur.get(key);
|
|
1269
1271
|
if (!next) {
|
|
1270
|
-
if (
|
|
1272
|
+
if (!isWeakKey(key)) {
|
|
1271
1273
|
this.badKey += 1;
|
|
1272
1274
|
return;
|
|
1273
1275
|
}
|
|
@@ -1280,7 +1282,7 @@ class WeakMapDomCache {
|
|
|
1280
1282
|
const leaf = cur.get(lastKey);
|
|
1281
1283
|
if (leaf)
|
|
1282
1284
|
leaf[cacheKey] = v;
|
|
1283
|
-
else if (
|
|
1285
|
+
else if (isWeakKey(lastKey))
|
|
1284
1286
|
cur.set(lastKey, { [cacheKey]: v });
|
|
1285
1287
|
else
|
|
1286
1288
|
this.badKey += 1;
|