Mercurial > hg
changeset 51858:2fd44b3dcc33 default tip
revlog: use the method to check if the revlog is being written to
This was probably fine, but it could become not fine at some point.
author | Raphaël Gomès <rgomes@octobus.net> |
---|---|
date | Wed, 19 Jun 2024 18:06:50 +0200 |
parents | b04011ca6eff |
children | |
files | mercurial/revlog.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/revlog.py Wed Jun 19 17:26:06 2024 +0200 +++ b/mercurial/revlog.py Wed Jun 19 18:06:50 2024 +0200 @@ -3160,7 +3160,7 @@ raise error.RevlogError( _(b"%s: attempt to add wdir revision") % self.display_id ) - if self._inner._writinghandles is None: + if not self._inner.is_writing: msg = b'adding revision outside `revlog._writing` context' raise error.ProgrammingError(msg)