Skip to content

Commit ff74bc1

Browse files
shuv1337Copilot
andauthored
Update packages/opencode/src/config/invalidation.ts
Co-authored-by: Copilot <[email protected]>
1 parent 8d408e6 commit ff74bc1

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

packages/opencode/src/config/invalidation.ts

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -175,13 +175,11 @@ export namespace ConfigInvalidation {
175175
}
176176
initialized = true
177177

178-
Bus.subscribe(Config.Event.Updated, async (event) => {
179-
if (!isConfigHotReloadEnabled()) {
180-
return
181-
}
182-
183-
const { diff, scope, directory, refreshed } = event.properties as any
184-
await apply({ diff, scope, directory, refreshed })
185-
})
178+
if (isConfigHotReloadEnabled()) {
179+
Bus.subscribe(Config.Event.Updated, async (event) => {
180+
const { diff, scope, directory, refreshed } = event.properties as any
181+
await apply({ diff, scope, directory, refreshed })
182+
})
183+
}
186184
}
187185
}

0 commit comments

Comments
 (0)