fallback for images without a tag cache

This commit is contained in:
byte[] 2019-12-08 14:30:17 -05:00
parent 179d8a27d9
commit 84eef46c78

View file

@ -154,7 +154,7 @@ defmodule PhilomenaWeb.ImageView do
defp image_filter_data(image) do
%{
id: image.id,
"namespaced_tags.name": String.split(image.tag_list_plus_alias_cache, ", "),
"namespaced_tags.name": String.split(image.tag_list_plus_alias_cache || "", ", "),
score: image.score,
faves: image.faves_count,
upvotes: image.upvotes_count,