mirror of
https://github.com/webstudio-is/webstudio.git
synced 2026-11-07 04:23:40 +09:00
fix !i
This commit is contained in:
1 parent
ebeb78ad6c
commit
e107260855
3 files changed
+3
-3
No files matched your search
@@ -4,7 +4,7 @@ import { type PubsubMap, useSubscribeAll } from "~/shared/pubsub";
|
||||
|
||||
const useSubscribeTreeChange = (onChange: () => void, isEnabled: boolean) => {
|
||||
const callback = useMemo(() => {
|
||||
if (!isEnabled) {
|
||||
if (isEnabled === false) {
|
||||
return () => null;
|
||||
}
|
||||
return (type: keyof PubsubMap) => {
|
||||
|
||||
@@ -24,7 +24,7 @@ export const Lock = ({
|
||||
const [isPaired, setIsPaired] = useState(aVal === bVal);
|
||||
|
||||
useEffect(() => {
|
||||
if (!isPaired) return;
|
||||
if (isPaired === false) return;
|
||||
if (aVal === bVal) return;
|
||||
batchUpdate.setProperty(aKey)(aVal);
|
||||
batchUpdate.setProperty(bKey)(aVal);
|
||||
|
||||
@@ -106,7 +106,7 @@ const updateTsConfig = async (
|
||||
const previousProp = ast.properties[referencesPropIndex - 1];
|
||||
const indent = formatted.match(/.*{\n(\s+)[^\s]/)?.[1];
|
||||
|
||||
if (!indent) {
|
||||
if (indent === undefined) {
|
||||
throw new Error(`Couldn't determine indentation`);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user