diff options
-rw-r--r-- | .rubocop_todo.yml | 8 | ||||
-rw-r--r-- | lib/redmine/export/pdf/issues_pdf_helper.rb | 4 | ||||
-rw-r--r-- | lib/redmine/export/pdf/wiki_pdf_helper.rb | 2 |
3 files changed, 3 insertions, 11 deletions
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index 8458b87ca..828010a53 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -1043,14 +1043,6 @@ Style/ExpandPathArguments: # Cop supports --auto-correct. # Configuration parameters: EnforcedStyle. -# SupportedStyles: each, for -Style/For: - Exclude: - - 'lib/redmine/export/pdf/issues_pdf_helper.rb' - - 'lib/redmine/export/pdf/wiki_pdf_helper.rb' - -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyle. # SupportedStyles: format, sprintf, percent Style/FormatString: Exclude: diff --git a/lib/redmine/export/pdf/issues_pdf_helper.rb b/lib/redmine/export/pdf/issues_pdf_helper.rb index b49691695..c6ee5a18f 100644 --- a/lib/redmine/export/pdf/issues_pdf_helper.rb +++ b/lib/redmine/export/pdf/issues_pdf_helper.rb @@ -189,7 +189,7 @@ module Redmine pdf.SetFontStyle('B',9) pdf.RDMCell(190,5, l(:label_associated_revisions), "B") pdf.ln - for changeset in issue.changesets + issue.changesets.each do |changeset| pdf.SetFontStyle('B',8) csstr = "#{l(:label_revision)} #{changeset.format_identifier} - " csstr += format_time(changeset.committed_on) + " - " + changeset.author.to_s @@ -240,7 +240,7 @@ module Redmine pdf.SetFontStyle('B',9) pdf.RDMCell(190,5, l(:label_attachment_plural), "B") pdf.ln - for attachment in issue.attachments + issue.attachments.each do |attachment| pdf.SetFontStyle('',8) pdf.RDMCell(80,5, attachment.filename) pdf.RDMCell(20,5, number_to_human_size(attachment.filesize),0,0,"R") diff --git a/lib/redmine/export/pdf/wiki_pdf_helper.rb b/lib/redmine/export/pdf/wiki_pdf_helper.rb index e2f408fc4..cc4ee6a17 100644 --- a/lib/redmine/export/pdf/wiki_pdf_helper.rb +++ b/lib/redmine/export/pdf/wiki_pdf_helper.rb @@ -87,7 +87,7 @@ module Redmine pdf.SetFontStyle('B', 9) pdf.RDMCell(190, 5, l(:label_attachment_plural), "B") pdf.ln - for attachment in page.attachments + page.attachments.each do |attachment| pdf.SetFontStyle('', 8) pdf.RDMCell(80, 5, attachment.filename) pdf.RDMCell(20, 5, number_to_human_size(attachment.filesize), 0, 0, "R") |