9155: Do not create an additional database access
This commit is contained in:
parent
9c8389f4ef
commit
fda0c4a91c
@ -532,8 +532,9 @@ class PeopleBaseModel(BaseModel):
|
|||||||
"""
|
"""
|
||||||
cached, value = self.get_cached_value(tag_handle, "TAG_NAME")
|
cached, value = self.get_cached_value(tag_handle, "TAG_NAME")
|
||||||
if not cached:
|
if not cached:
|
||||||
if self.db.get_tag_from_handle(tag_handle):
|
tag = self.db.get_tag_from_handle(tag_handle)
|
||||||
value = self.db.get_tag_from_handle(tag_handle).get_name()
|
if tag:
|
||||||
|
value = tag.get_name()
|
||||||
self.set_cached_value(tag_handle, "TAG_NAME", value)
|
self.set_cached_value(tag_handle, "TAG_NAME", value)
|
||||||
return value
|
return value
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user