Filter out empty traits
This commit is contained in:
parent
c7d484fa9a
commit
24a9683608
@ -74,6 +74,7 @@ def show_action(name):
|
|||||||
item["_all_traits"].append(_traits.get("rarity", {}).get("value", "unkown rarity"))
|
item["_all_traits"].append(_traits.get("rarity", {}).get("value", "unkown rarity"))
|
||||||
item["_all_traits"] += _traits.get("value", [])
|
item["_all_traits"] += _traits.get("value", [])
|
||||||
item["_all_traits"] += _traits.get("custom").split(',')
|
item["_all_traits"] += _traits.get("custom").split(',')
|
||||||
|
item["_all_traits"] = list(filter(lambda x: x != '', item["_all_traits"]))
|
||||||
return render_template("action.html", action=item)
|
return render_template("action.html", action=item)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
Loading…
Reference in New Issue
Block a user