diff -r 7a8ea1397816 -r d718eddf01d9 hgext/fsmonitor/__init__.py --- a/hgext/fsmonitor/__init__.py Thu Dec 08 15:33:19 2022 +0100 +++ b/hgext/fsmonitor/__init__.py Thu Aug 31 23:56:15 2023 +0200 @@ -332,7 +332,7 @@ matchfn = match.matchfn matchalways = match.always() dmap = self._map - if util.safehasattr(dmap, b'_map'): + if hasattr(dmap, b'_map'): # for better performance, directly access the inner dirstate map if the # standard dirstate implementation is in use. dmap = dmap._map @@ -744,7 +744,7 @@ def wrapdirstate(orig, self): ds = orig(self) # only override the dirstate when Watchman is available for the repo - if util.safehasattr(self, b'_fsmonitorstate'): + if hasattr(self, b'_fsmonitorstate'): makedirstate(self, ds) return ds @@ -811,7 +811,7 @@ self.oldnode = self.repo[b'.'].node() if self.repo.currentwlock() is None: - if util.safehasattr(self.repo, b'wlocknostateupdate'): + if hasattr(self.repo, b'wlocknostateupdate'): self._lock = self.repo.wlocknostateupdate() else: self._lock = self.repo.wlock() @@ -839,7 +839,7 @@ self._lock.release() def _state(self, cmd, commithash, status=b'ok'): - if not util.safehasattr(self.repo, b'_watchmanclient'): + if not hasattr(self.repo, b'_watchmanclient'): return False try: self.repo._watchmanclient.command(