equal
deleted
inserted
replaced
1448 # Not all storage may be revlogs. If requested, try to return an actual |
1448 # Not all storage may be revlogs. If requested, try to return an actual |
1449 # revlog instance. |
1449 # revlog instance. |
1450 if returnrevlog: |
1450 if returnrevlog: |
1451 if isinstance(r, revlog.revlog): |
1451 if isinstance(r, revlog.revlog): |
1452 pass |
1452 pass |
1453 elif util.safehasattr(r, b'_revlog'): |
1453 elif util.safehasattr(r, '_revlog'): |
1454 r = r._revlog # pytype: disable=attribute-error |
1454 r = r._revlog # pytype: disable=attribute-error |
1455 elif r is not None: |
1455 elif r is not None: |
1456 raise error.InputError( |
1456 raise error.InputError( |
1457 _(b'%r does not appear to be a revlog') % r |
1457 _(b'%r does not appear to be a revlog') % r |
1458 ) |
1458 ) |