def allow_pathlib(func):
    'Allow methods to receive pathlib.Path objects.\n\n    Parameters\n    ----------\n    func: callable\n        function to decorate must have the following signature\n        self, path, *args, **kwargs\n\n    Returns\n    -------\n    wrapper: callable\n    '

    @wraps(func)
    def wrapper(self, path, *args, **kwargs):
        from drfs.path import asstr
        p = asstr(path)
        return func(self, p, *args, **kwargs)
    return wrapper
Allow methods to receive pathlib.Path objects.

Parameters
----------
func: callable
    function to decorate must have the following signature
    self, path, *args, **kwargs

Returns
-------
wrapper: callable
def allow_pathlib(func):
    'Allow methods to receive pathlib.Path objects.\n\n    Parameters\n    ----------\n    func: callable\n        function to decorate must have the following signature\n        self, path, *args, **kwargs\n\n    Returns\n    -------\n    wrapper: callable\n    '

    @wraps(func)
    def wrapper(self, path, *args, **kwargs):
        from drfs.path import asstr
        p = asstr(path)
        return func(self, p, *args, **kwargs)
    return wrapper