@domql/state
Advanced tools
Comparing version 2.5.3 to 2.5.7
@@ -56,16 +56,14 @@ 'use strict' | ||
return exec(state, element) | ||
} | ||
if (is(state)('string', 'number')) { | ||
} else if (is(state)('string', 'number')) { | ||
ref.__state = state | ||
return {} | ||
} | ||
if (state === true) { | ||
} else if (state === true) { | ||
ref.__state = element.key | ||
return {} | ||
} | ||
if (state) { | ||
} else if (state) { | ||
ref.__hasRootState = true | ||
return state | ||
} else { | ||
return false | ||
} | ||
return false | ||
} | ||
@@ -72,0 +70,0 @@ |
@@ -69,16 +69,14 @@ "use strict"; | ||
return (0, import_utils.exec)(state, element); | ||
} | ||
if ((0, import_utils.is)(state)("string", "number")) { | ||
} else if ((0, import_utils.is)(state)("string", "number")) { | ||
ref.__state = state; | ||
return {}; | ||
} | ||
if (state === true) { | ||
} else if (state === true) { | ||
ref.__state = element.key; | ||
return {}; | ||
} | ||
if (state) { | ||
} else if (state) { | ||
ref.__hasRootState = true; | ||
return state; | ||
} else { | ||
return false; | ||
} | ||
return false; | ||
}; | ||
@@ -85,0 +83,0 @@ const addProtoToArray = (state, proto) => { |
@@ -71,2 +71,3 @@ 'use strict' | ||
const stateKey = ref.__state | ||
if (!stateKey || isNot(stateKey)('number', 'string')) return false | ||
@@ -73,0 +74,0 @@ return true |
{ | ||
"name": "@domql/state", | ||
"version": "2.5.3", | ||
"version": "2.5.7", | ||
"license": "MIT", | ||
@@ -34,3 +34,3 @@ "type": "module", | ||
}, | ||
"gitHead": "8a498068958fca26ce39c39e6ad1312d0be327d7" | ||
"gitHead": "fe6520d996b2ca837f6965928a51360ea91e9695" | ||
} |
36375
960