mirror of
https://github.com/redmine/redmine.git
synced 2026-03-20 11:22:06 +01:00
pdf: backport r8731 (#10505)
Fixed that tag[0] may be nil. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/1.3-stable@9278 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
4
vendor/plugins/rfpdf/lib/tcpdf.rb
vendored
4
vendor/plugins/rfpdf/lib/tcpdf.rb
vendored
@@ -3474,7 +3474,7 @@ class TCPDF
|
||||
#Extract attributes
|
||||
# get tag name
|
||||
tag = element.scan(/([a-zA-Z0-9]*)/).flatten.delete_if {|x| x.length == 0}
|
||||
tag = tag[0].downcase;
|
||||
tag = tag[0].to_s.downcase;
|
||||
|
||||
# get attributes
|
||||
attr_array = element.scan(/([^=\s]*)=["\']?([^"\']*)["\']?/)
|
||||
@@ -3497,7 +3497,7 @@ class TCPDF
|
||||
#Extract attributes
|
||||
# get tag name
|
||||
tag = element.scan(/([a-zA-Z0-9]*)/).flatten.delete_if {|x| x.length == 0}
|
||||
tag = tag[0].downcase;
|
||||
tag = tag[0].to_s.downcase;
|
||||
|
||||
# get attributes
|
||||
attr_array = element.scan(/([^=\s]*)=["\']?([^"\']*)["\']?/)
|
||||
|
||||
Reference in New Issue
Block a user