This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new 57dbc2d0 Fix crash
57dbc2d0 is described below

commit 57dbc2d06773a1b837d2defaff8f5d3bf912c6ed
Author: Sebb <[email protected]>
AuthorDate: Mon Jan 13 22:59:35 2025 +0000

    Fix crash
---
 tools/download_check.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/download_check.rb b/tools/download_check.rb
index d6255427..7227668c 100755
--- a/tools/download_check.rb
+++ b/tools/download_check.rb
@@ -496,7 +496,7 @@ def _checkDownloadPage(path, tlp, version)
   body.scan(%r{gpg --verify.+$}) { |m|
     hasGPGverify = true
     # Hack to tidy matched text: drop spans and truncate at <br> or <div>
-    m.gsub!(%r{<span [^>]+>|</span>}, '').sub!(%r{(<div|<br).+},'')
+    m = m.gsub(%r{<span [^>]+>|</span>}, '').sub(%r{(<div|<br).+},'') # sub! 
returns nil if no change
     unless m =~ %r{gpg --verify\s+\S+\.asc\s+\S+}
       W "gpg verify should specify second param: #{m.strip} 
see:\nhttps://www.apache.org/info/verification.html#specify_both";
     end

Reply via email to