From da913b9a9b302513f312b1fe6dd0246805eb29a5 Mon Sep 17 00:00:00 2001 From: Tomas Babej Date: Thu, 24 Dec 2015 17:56:55 +0100 Subject: [PATCH] lazy: Properly override getattr calls --- tasklib/lazy.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tasklib/lazy.py b/tasklib/lazy.py index 543abf0..04ccdf5 100644 --- a/tasklib/lazy.py +++ b/tasklib/lazy.py @@ -29,7 +29,7 @@ class LazyUUIDTask(object): # Getattr is called only if the attribute could not be found using # normal means self.replace() - return self.name + return getattr(self, name) def __eq__(self, other): if other['uuid']: @@ -83,7 +83,7 @@ class LazyUUIDTaskSet(object): raise AttributeError else: self.replace() - return self.name + return getattr(self, name) def __repr__(self): return "LazyUUIDTaskSet([{0}])".format(', '.join(self._uuids)) -- 2.39.5