From b891818b9cd34ec59878eeb04f1880f4a006a0de Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 6 Oct 2011 20:42:31 +0200 Subject: [PATCH] remove obsolete get_type_from_object() and use Object.type Signed-off-by: Nico Schottelius --- lib/cdist/config_install.py | 2 +- lib/cdist/path.py | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/cdist/config_install.py b/lib/cdist/config_install.py index 3c11d6bb..2071a0e9 100644 --- a/lib/cdist/config_install.py +++ b/lib/cdist/config_install.py @@ -78,7 +78,7 @@ class ConfigInstall: def run_type_explorer(self, cdist_object): """Run type specific explorers for objects""" - type = self.path.get_type_from_object(cdist_object) + type = cdist_object.type self.path.transfer_type_explorers(type) cmd = [] diff --git a/lib/cdist/path.py b/lib/cdist/path.py index 98572b81..d82ae974 100644 --- a/lib/cdist/path.py +++ b/lib/cdist/path.py @@ -192,11 +192,6 @@ class Path: return object_paths - # FIXME: Object - def get_type_from_object(self, cdist_object): - """Returns the first part (i.e. type) of an object""" - return cdist_object.split(os.sep)[0] - # FIXME: Object def get_object_id_from_object(self, cdist_object): """Returns everything but the first part (i.e. object_id) of an object"""