diff options
author | Anthony Sottile <asottile@umich.edu> | 2019-02-25 22:32:27 (GMT) |
---|---|---|
committer | Giampaolo Rodola <g.rodola@gmail.com> | 2019-02-25 22:32:27 (GMT) |
commit | 8377cd4fcd0d51d86834c9b0518d29aac3b49e18 (patch) | |
tree | e8d82c3567b2d39ff0bd285d25ce2d02359ae070 /Lib/dbm | |
parent | 9c3f284de598550be6687964c23fd7599e53b20e (diff) | |
download | cpython-8377cd4fcd0d51d86834c9b0518d29aac3b49e18.zip cpython-8377cd4fcd0d51d86834c9b0518d29aac3b49e18.tar.gz cpython-8377cd4fcd0d51d86834c9b0518d29aac3b49e18.tar.bz2 |
Clean up code which checked presence of os.{stat,lstat,chmod} (#11643)
Diffstat (limited to 'Lib/dbm')
-rw-r--r-- | Lib/dbm/dumb.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/dbm/dumb.py b/Lib/dbm/dumb.py index 6cef72a..864ad37 100644 --- a/Lib/dbm/dumb.py +++ b/Lib/dbm/dumb.py @@ -278,8 +278,7 @@ class _Database(collections.abc.MutableMapping): __del__ = close def _chmod(self, file): - if hasattr(self._os, 'chmod'): - self._os.chmod(file, self._mode) + self._os.chmod(file, self._mode) def __enter__(self): return self |