Change decorators to use a relative import.

This is more consistent with the way the rest of the package
imports errors. This also solves a crazy cyclical import issue
I'm seeing.

Signed-off-by: dlorenc <lorenc.d@gmail.com>
This commit is contained in:
dlorenc 2015-04-27 18:50:31 -07:00
parent 85c0c3b0e3
commit a7b2a1bff3
1 changed files with 2 additions and 2 deletions

View File

@ -1,4 +1,4 @@
import docker.errors
from .. import errors
def check_resource(f):
@ -6,7 +6,7 @@ def check_resource(f):
if resource_id is None and (
kwargs.get('container') is None and kwargs.get('image') is None
):
raise docker.errors.NullResource(
raise errors.NullResource(
'image or container param is None'
)
return f(self, resource_id, *args, **kwargs)