From f7bf36d8fc5f8a7638a2cee215513c1dcd4f4a96 Mon Sep 17 00:00:00 2001 From: Akihiko Odaki Date: Sun, 4 Feb 2018 02:41:01 +0900 Subject: [PATCH] Require environment for generate_static_pages (#6420) It is required for ApplicationController. --- lib/tasks/assets.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tasks/assets.rake b/lib/tasks/assets.rake index f60c1b9f20..0826f01864 100644 --- a/lib/tasks/assets.rake +++ b/lib/tasks/assets.rake @@ -9,7 +9,7 @@ end namespace :assets do desc 'Generate static pages' - task :generate_static_pages do + task generate_static_pages: :environment do render_static_page 'errors/500', layout: 'error', dest: Rails.root.join('public', 'assets', '500.html') end end