diff --git a/lib/flowerbox/runner/base.rb b/lib/flowerbox/runner/base.rb index e9cb42a..3cc396d 100644 --- a/lib/flowerbox/runner/base.rb +++ b/lib/flowerbox/runner/base.rb @@ -95,6 +95,8 @@ module Flowerbox raise RunnerDiedError.new if attempts == 0 Flowerbox.server = nil + ensure + @sprockets.reset! end end diff --git a/lib/flowerbox/sprockets_handler.rb b/lib/flowerbox/sprockets_handler.rb index 3b5ab4e..83c8959 100644 --- a/lib/flowerbox/sprockets_handler.rb +++ b/lib/flowerbox/sprockets_handler.rb @@ -69,6 +69,10 @@ module Flowerbox raise LogicalPathNotFoundError.new("Could not find logical path for #{asset_path}") end + + def reset! + @environment.send(:expire_index!) + end end end