From 09cf6a0d2666d51ca18a840c1770895bce127116 Mon Sep 17 00:00:00 2001 From: Damian Kaczmarek Date: Wed, 22 Oct 2014 13:24:19 +0200 Subject: [PATCH] Workaround/fix for build/run config not containing user config data --- lib/requirejs/rails/config.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/requirejs/rails/config.rb b/lib/requirejs/rails/config.rb index 93862abf..aa039987 100644 --- a/lib/requirejs/rails/config.rb +++ b/lib/requirejs/rails/config.rb @@ -88,7 +88,7 @@ def initialize(application) uglify uglify2 useStrict - wrap + wrapShim } end @@ -133,6 +133,9 @@ def user_config=(cfg) if url = cfg.delete('baseUrl') raise Requirejs::ConfigError, "baseUrl is not needed or permitted in the configuration" end + # delete any cached configs, will be lazily resolved + self.delete(:build_config) + self.delete(:run_config) self[:user_config] = cfg end