Method decorator factory that triggers a registry refresh around
the decorated method.
when: 'before' (default): refresh runs first so the method body
reads a fresh registry. Refresh errors propagate to the caller.
when: 'after': refresh runs post-method to capture server-side
mutations whose response carries no device fields (Classic
frost/holiday envelopes, Home setpoint PUTs). Fail-soft —
refresh failures are logged and swallowed so a stale-registry
error cannot mask the landed mutation.
Refresh path is resolved structurally via the FetchDevicesHost
shape (the host must expose fetch() or registry.syncDevices()).
Method decorator factory that triggers a registry refresh around the decorated method.
when: 'before'(default): refresh runs first so the method body reads a fresh registry. Refresh errors propagate to the caller.when: 'after': refresh runs post-method to capture server-side mutations whose response carries no device fields (Classic frost/holiday envelopes, Home setpoint PUTs). Fail-soft — refresh failures are logged and swallowed so a stale-registry error cannot mask the landed mutation.Refresh path is resolved structurally via the
FetchDevicesHostshape (the host must exposefetch()orregistry.syncDevices()).