From fec86a9ce100dec444872993c792fa99cc489b96 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sun, 7 Dec 2008 15:21:40 +0000 Subject: Adds a setting to limit the number of diff lines that should be displayed (default to 1500). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2112 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/views/common/_diff.rhtml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'app/views/common') diff --git a/app/views/common/_diff.rhtml b/app/views/common/_diff.rhtml index 07bd4745f..104845b4d 100644 --- a/app/views/common/_diff.rhtml +++ b/app/views/common/_diff.rhtml @@ -1,4 +1,5 @@ -<% Redmine::UnifiedDiff.new(diff, :type => diff_type).each do |table_file| -%> +<% diff = Redmine::UnifiedDiff.new(diff, :type => diff_type, :max_lines => Setting.diff_max_lines_displayed.to_i) -%> +<% diff.each do |table_file| -%>
<% if diff_type == 'sbs' -%> @@ -62,3 +63,5 @@ <% end -%> + +<%= l(:text_diff_truncated) if diff.truncated? %> -- cgit v1.2.3