Set view_context if it's nil.
This should take care of #244, but also in general, anywhere that we haven't primed the context yet.
This commit is contained in:
parent
57617ba0d4
commit
057ab4e86f
|
@ -1,7 +1,7 @@
|
|||
module Draper
|
||||
module ViewContext
|
||||
def self.current
|
||||
Thread.current[:current_view_context]
|
||||
Thread.current[:current_view_context] || view_context
|
||||
end
|
||||
|
||||
def self.current=(input)
|
||||
|
|
Loading…
Reference in New Issue