reorder attr.ib specs

This commit is contained in:
Ronny Pfannschmidt 2018-06-18 14:01:06 +02:00
parent 23581d44bd
commit fb992a0c81
1 changed files with 2 additions and 2 deletions

View File

@ -27,6 +27,8 @@ log = logging.getLogger(__name__)
@attr.s
class Cache(object):
_cachedir = attr.ib(repr=False)
@classmethod
def for_config(cls, config):
cachedir = cls.cache_dir_from_config(config)
@ -35,8 +37,6 @@ class Cache(object):
cachedir.mkdir()
return cls(cachedir)
_cachedir = attr.ib(repr=False)
@staticmethod
def cache_dir_from_config(config):
return paths.resolve_from_str(config.getini("cache_dir"), config.rootdir)