From 96ca5b6988f249b8320c977d3242846b2e1f0519 Mon Sep 17 00:00:00 2001 From: Steven Armstrong Date: Mon, 10 Oct 2011 09:48:19 +0200 Subject: [PATCH] bugfix: use absolute path to when accessing file sytem (unittest discoverd :-) Signed-off-by: Steven Armstrong --- lib/cdist/core/object.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cdist/core/object.py b/lib/cdist/core/object.py index b6bdeee3..96c6076a 100644 --- a/lib/cdist/core/object.py +++ b/lib/cdist/core/object.py @@ -114,7 +114,7 @@ class Object(object): @property def parameters(self): if not self.__parameters: - self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.path, "parameter")) + self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.absolute_path, "parameter")) return self.__parameters @parameters.setter @@ -122,7 +122,7 @@ class Object(object): if isinstance(value, cdist.core.property.DirectoryDict): self.__parameters = value else: - self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.path, "parameter"), value) + self.__parameters = cdist.core.property.DirectoryDict(os.path.join(self.absolute_path, "parameter"), value) ### /parameters