Bugzilla – Attachment 190929 Details for
Bug 41060
Add a value_builder to check if ISSN is valid
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 41060: (QA follow-up) improve ISSN format detection
Bug-41060-QA-follow-up-improve-ISSN-format-detecti.patch (text/plain), 1.17 KB, created by
Arthur Suzuki
on 2026-01-06 12:44:36 UTC
(
hide
)
Description:
Bug 41060: (QA follow-up) improve ISSN format detection
Filename:
MIME Type:
Creator:
Arthur Suzuki
Created:
2026-01-06 12:44:36 UTC
Size:
1.17 KB
patch
obsolete
>From cea3e7d24f5016ee0428c5ac2f2a981fab99566f Mon Sep 17 00:00:00 2001 >From: Arthur Suzuki <arthur.suzuki@biblibre.com> >Date: Tue, 6 Jan 2026 10:03:52 +0000 >Subject: [PATCH] Bug 41060: (QA follow-up) improve ISSN format detection > >Two tests have been added: >- not only the checksum of the ISSN is checked but also the format. >- if the ISSN is left empty, the plugin won't give a warning. >--- > cataloguing/value_builder/validate_issn.pl | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > >diff --git a/cataloguing/value_builder/validate_issn.pl b/cataloguing/value_builder/validate_issn.pl >index 7bda38082b0..d4df82c0bbc 100755 >--- a/cataloguing/value_builder/validate_issn.pl >+++ b/cataloguing/value_builder/validate_issn.pl >@@ -60,7 +60,13 @@ my $launcher = sub { > flagsrequired => { editcatalogue => '*' }, > } > ); >- my $is_valid = is_valid_checksum($issn); >+ my $is_valid = 0; >+ if ($issn =~ /^\d{4}-\d{3}[\dXx]$/) { >+ $is_valid = is_valid_checksum($issn); >+ } >+ if ($issn eq '') { >+ $is_valid = 1; >+ } > $template->param( return => $is_valid ); > output_html_with_http_headers $cgi, $cookie, $template->output; > }; >-- >2.39.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 41060
:
188200
|
188418
|
190929
|
190930
|
190943
|
190944
|
191557
|
191558
|
191559
|
191560