File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -239,18 +239,18 @@ def method_missing(method_name, *args) # rubocop:disable Style/MissingRespondToM
239239 rescue => e # rubocop:disable Style/RescueStandardError
240240 e . set_backtrace e . backtrace . tap ( &:shift )
241241 if ViewComponent ::Base . strict_helpers_enabled
242- raise e , <<~MESSAGE . chomp if view_context && e . is_a? ( NameError ) && ( __vc_original_view_context . respond_to? ( method_name ) || controller . view_context . respond_to? ( method_name ) )
243- #{ e . message }
242+ raise e , <<~MESSAGE . chomp if view_context && e . is_a? ( NameError ) && ( __vc_original_view_context . respond_to? ( method_name ) || controller . view_context . respond_to? ( method_name ) )
243+ #{ e . message }
244244
245- You may be trying to call a method provided as a view helper. To use it try decalring it using use_helpers :#{ method_name } '?
245+ You may be trying to call a method provided as a view helper. To use it try decalring it using use_helpers :#{ method_name } '?
246246 MESSAGE
247- else
248- raise e , <<~MESSAGE . chomp if view_context && e . is_a? ( NameError ) && helpers . respond_to? ( method_name )
247+ elsif view_context && e . is_a? ( NameError ) && helpers . respond_to? ( method_name )
248+ raise e , <<~MESSAGE . chomp
249+ end
249250 #{ e . message }
250251
251252 You may be trying to call a method provided as a view helper. Did you mean `helpers.#{ method_name } '?
252253 MESSAGE
253- end
254254
255255 raise
256256 end
You can’t perform that action at this time.
0 commit comments