From: Go MAEDA Date: Thu, 1 Apr 2021 14:54:36 +0000 (+0000) Subject: Fix "ActionView::Template::Error (wrong number of arguments (given 2, expected 1... X-Git-Tag: 5.0.0~473 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7de9711f25b1c8abcdf2a154e3870dcc93b89989;p=redmine.git Fix "ActionView::Template::Error (wrong number of arguments (given 2, expected 1))" (#29914). Patch by Marius BALTEANU. git-svn-id: http://svn.redmine.org/redmine/trunk@20886 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/lib/redmine/views/api_template_handler.rb b/lib/redmine/views/api_template_handler.rb index e777e1a70..0b31d33ef 100644 --- a/lib/redmine/views/api_template_handler.rb +++ b/lib/redmine/views/api_template_handler.rb @@ -20,7 +20,7 @@ module Redmine module Views class ApiTemplateHandler - def self.call(template) + def self.call(template, source = nil) "Redmine::Views::Builders.for(params[:format], request, response) do |api|; #{template.source}; self.output_buffer = api.output; end" end end