From faf8364050c0a3925a8b2af85b6b5c9e94090986 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Mon, 22 Dec 2008 16:58:48 -0600 Subject: Defining a new method is atomic, no mutex needed. --- actionpack/lib/action_view/renderable.rb | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'actionpack/lib/action_view') diff --git a/actionpack/lib/action_view/renderable.rb b/actionpack/lib/action_view/renderable.rb index 4a5b36d70a..d8e72f1179 100644 --- a/actionpack/lib/action_view/renderable.rb +++ b/actionpack/lib/action_view/renderable.rb @@ -4,10 +4,6 @@ module ActionView module Renderable #:nodoc: extend ActiveSupport::Memoizable - def self.included(base) - @@mutex = Mutex.new - end - def filename 'compiled-template' end @@ -64,10 +60,8 @@ module ActionView def compile(local_assigns) render_symbol = method_name(local_assigns) - @@mutex.synchronize do - if recompile?(render_symbol) - compile!(render_symbol, local_assigns) - end + if recompile?(render_symbol) + compile!(render_symbol, local_assigns) end end -- cgit v1.2.3