diff --git a/app/models/site/build_stats.rb b/app/models/site/build_stats.rb index d5b0c1ad..d5461bcf 100644 --- a/app/models/site/build_stats.rb +++ b/app/models/site/build_stats.rb @@ -45,7 +45,7 @@ class Site # # @return [Boolean] def awaiting_publication? - waiting? && updated_at > (build_stats.jekyll.where(status: true).last&.created_at || updated_at) + waiting? && updated_at >= (indexed_posts.order(updated_at: :desc).select(:created_at).first&.created_at || 1.second.ago) end end end