Skip to content

Commit

Permalink
Fix AccessMode enum for old python versions
Browse files Browse the repository at this point in the history
  • Loading branch information
alfred82santa committed Apr 15, 2020
1 parent 13e1ffe commit c6b2172
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions dirty_models/base.py
Expand Up @@ -8,14 +8,14 @@

from abc import abstractmethod

from enum import IntEnum, auto
from enum import IntEnum


class AccessMode(IntEnum):
READ_AND_WRITE = 0
WRITABLE_ONLY_ON_CREATION = auto()
READ_ONLY = auto()
HIDDEN = auto()
WRITABLE_ONLY_ON_CREATION = 1
READ_ONLY = 2
HIDDEN = 3

def __and__(self, other):
return max(self, other)
Expand Down

0 comments on commit c6b2172

Please sign in to comment.