diff options
author | Ivan Kohler <ivan@freeside.biz> | 2018-01-10 16:42:00 -0800 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2018-01-10 16:42:00 -0800 |
commit | 0c9802e5aeff0c80059db9f14135cf4826bf500b (patch) | |
tree | 93164fcc7892734728c11585970d193a9678e3aa /httemplate | |
parent | f8f2ef5ae14c08397b1af8986a1cf5831c453e21 (diff) |
fix direct use of customer_view_emails pref, RT#78617
Diffstat (limited to 'httemplate')
-rw-r--r-- | httemplate/view/cust_main/notes/email.html | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/httemplate/view/cust_main/notes/email.html b/httemplate/view/cust_main/notes/email.html index 41c5b8ad4..9e217e4f0 100644 --- a/httemplate/view/cust_main/notes/email.html +++ b/httemplate/view/cust_main/notes/email.html @@ -61,7 +61,10 @@ my $cust_main = $opt{'cust_main'} my $custnum = $cust_main->custnum; my $where = "WHERE cust_msg.custnum = $custnum"; -my $maxrecords = $curuser->option('customer_view_emails') || 10; +my $maxrecords = 10; +if ( $curuser->option('customer_view_emails') =~ /^\s*(\d+)\s*$/ ) { + $maxrecords = $1; +} my $order_by = '_date DESC'; |