Bugzilla – Attachment 32080 Details for
Bug 13050
Follow-up for bug 12371 on self-registration verification notice
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 13050: Follow-up for bug 12371
Bug-13050-Follow-up-for-bug-12371.patch (text/plain), 2.58 KB, created by
Marcel de Rooy
on 2014-10-09 11:23:26 UTC
(
hide
)
Description:
Bug 13050: Follow-up for bug 12371
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2014-10-09 11:23:26 UTC
Size:
2.58 KB
patch
obsolete
>From 1f74bdaf063c0a9691caa8da1c039d5c63c4cd7f Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 9 Oct 2014 13:09:47 +0200 >Subject: [PATCH] Bug 13050: Follow-up for bug 12371 >Content-Type: text/plain; charset=utf-8 > >This patch simplifies the SQL query in Letters.pm for table >borrower_modifications. >It also addresses the only case this query is used in opac-memberentry. >An unused variable in Letters.pm is removed. > >Test plan: >Enable selfregistration on opac. >Set verification by email to required in prefs too. >Self-register two new users. >Check the email notices generated. >Verify the new users with the tokens in their notice. >--- > C4/Letters.pm | 3 +-- > opac/opac-memberentry.pl | 3 +-- > 2 files changed, 2 insertions(+), 4 deletions(-) > >diff --git a/C4/Letters.pm b/C4/Letters.pm >index 912294e..4a10cac 100644 >--- a/C4/Letters.pm >+++ b/C4/Letters.pm >@@ -535,7 +535,6 @@ sub _substitute_tables { > $values = $param; > } > else { >- my @pk; > my $sth = _parseletter_sth($table); > unless ($sth) { > warn "_parseletter_sth('$table') failed to return a valid sth. No substitution will be done for that table."; >@@ -575,7 +574,7 @@ sub _parseletter_sth { > ($table eq 'aqbooksellers') ? "SELECT * FROM $table WHERE id = ?" : > ($table eq 'aqorders' ) ? "SELECT * FROM $table WHERE ordernumber = ?" : > ($table eq 'opac_news' ) ? "SELECT * FROM $table WHERE idnew = ?" : >- ($table eq 'borrower_modifications') ? "SELECT * FROM $table WHERE ( borrowernumber = 0 OR borrowernumber = ? ) AND ( verification_token = '' OR verification_token = ? ) AND ( verification_token != '' OR borrowernumber != 0 )" : >+ ($table eq 'borrower_modifications') ? "SELECT * FROM $table WHERE verification_token = ?" : > undef ; > unless ($query) { > warn "ERROR: No _parseletter_sth query for table '$table'"; >diff --git a/opac/opac-memberentry.pl b/opac/opac-memberentry.pl >index 8ca517b..6abe803 100755 >--- a/opac/opac-memberentry.pl >+++ b/opac/opac-memberentry.pl >@@ -115,8 +115,7 @@ if ( $action eq 'create' ) { > module => 'members', > letter_code => 'OPAC_REG_VERIFY', > tables => { >- borrower_modifications => >- [ $verification_token, $verification_token ], >+ borrower_modifications => $verification_token, > }, > ); > >-- >1.7.7.6
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 13050
:
32080
|
32750
|
32772