exclude empty tags from tag cache (#1012)
This commit is contained in:
@@ -3,6 +3,7 @@ class ApiCacheGenerator
|
||||
File.open("#{Rails.root}/public/cache/tags.json", "w") do |f|
|
||||
f.print("[")
|
||||
Tag.find_each do |tag|
|
||||
next unless tag.post_count > 0
|
||||
hash = {
|
||||
"name" => tag.name,
|
||||
"id" => tag.id,
|
||||
|
||||
Reference in New Issue
Block a user