Mercurial > public > mercurial-scm > hg-stable
diff hgext/lfs/wireprotolfsserver.py @ 50951:d718eddf01d9
safehasattr: drop usage in favor of hasattr
The two functions should now be equivalent at least in their usage in core.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Thu, 31 Aug 2023 23:56:15 +0200 |
parents | dde4b55a0785 |
children | f4733654f144 |
line wrap: on
line diff
--- a/hgext/lfs/wireprotolfsserver.py Thu Dec 08 15:33:19 2022 +0100 +++ b/hgext/lfs/wireprotolfsserver.py Thu Aug 31 23:56:15 2023 +0200 @@ -16,7 +16,6 @@ from mercurial import ( exthelper, pycompat, - util, wireprotoserver, ) @@ -44,7 +43,7 @@ if not rctx.repo.ui.configbool(b'experimental', b'lfs.serve'): return False - if not util.safehasattr(rctx.repo.svfs, 'lfslocalblobstore'): + if not hasattr(rctx.repo.svfs, 'lfslocalblobstore'): return False if not req.dispatchpath: