File tree 1 file changed +7
-5
lines changed
1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -73,16 +73,18 @@ def render_in(view_context, &block)
73
73
# TODO flag with initializer
74
74
if !self . __vc_original_view_context
75
75
view_context . output_buffer = ActionView ::OutputBuffer . new if !view_context . output_buffer
76
- self . __vc_original_view_context ||= view_context
77
- if self . __vc_original_view_context . global_buffer_coordinator . nil?
78
- coordinator = self . __vc_original_view_context . global_buffer_coordinator = GlobalBuffer ::Coordinator . new
79
- coordinator . subscribe ( self . __vc_original_view_context )
76
+
77
+ if view_context . global_buffer_coordinator . nil?
78
+ coordinator = view_context . global_buffer_coordinator = GlobalBuffer ::Coordinator . new
79
+ coordinator . subscribe ( view_context )
80
80
end
81
+
82
+ self . __vc_original_view_context = view_context
81
83
end
82
84
83
85
@output_buffer = self . __vc_original_view_context . output_buffer
84
86
self . global_buffer_coordinator = self . __vc_original_view_context . global_buffer_coordinator
85
- self . __vc_original_view_context . global_buffer_coordinator . subscribe ( self )
87
+ self . global_buffer_coordinator . subscribe ( self )
86
88
87
89
@lookup_context ||= view_context . lookup_context
88
90
You can’t perform that action at this time.
0 commit comments