mirror of https://github.com/docker/docker-py.git
Merge pull request #572 from dlorenc/master
Change decorators to use a relative import.
This commit is contained in:
commit
aceb7a69b5
|
@ -1,4 +1,4 @@
|
||||||
import docker.errors
|
from .. import errors
|
||||||
|
|
||||||
|
|
||||||
def check_resource(f):
|
def check_resource(f):
|
||||||
|
@ -6,7 +6,7 @@ def check_resource(f):
|
||||||
if resource_id is None and (
|
if resource_id is None and (
|
||||||
kwargs.get('container') is None and kwargs.get('image') is None
|
kwargs.get('container') is None and kwargs.get('image') is None
|
||||||
):
|
):
|
||||||
raise docker.errors.NullResource(
|
raise errors.NullResource(
|
||||||
'image or container param is None'
|
'image or container param is None'
|
||||||
)
|
)
|
||||||
return f(self, resource_id, *args, **kwargs)
|
return f(self, resource_id, *args, **kwargs)
|
||||||
|
|
Loading…
Reference in New Issue