From d8e721d328007477b5d314323809c15c16f6d45a Mon Sep 17 00:00:00 2001 From: Jonathon Date: Fri, 6 Dec 2024 08:45:07 +0000 Subject: [PATCH] Force autoload of lib for Zeitwerk Zeitwerk requries lib to be autoloaded early so it can be properly initialised. Previously this had been set to eager-load erroneously. --- config/application.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/application.rb b/config/application.rb index f35b08c7948..2d62be05acf 100644 --- a/config/application.rb +++ b/config/application.rb @@ -64,7 +64,7 @@ class Application < Rails::Application config.action_dispatch.ignore_accept_header = true # Force lib autoload, which was removed by Rails 3.0 and enforced by Zeitwerk - config.eager_load_paths << Rails.root.join("lib") + config.autoload_paths << Rails.root.join("lib") # Allow requests for all domains e.g. .dev.gov.uk config.hosts.clear