Bugzilla – Attachment 64325 Details for
Bug 18801
Merging authorities has an invalid 'Default' type in the merge framework selector
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18801: [Follow-up] Dbrev to repair bad auth type codes
Bug-18801-Follow-up-Dbrev-to-repair-bad-auth-type-.patch (text/plain), 1.38 KB, created by
Marcel de Rooy
on 2017-06-15 13:50:22 UTC
(
hide
)
Description:
Bug 18801: [Follow-up] Dbrev to repair bad auth type codes
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2017-06-15 13:50:22 UTC
Size:
1.38 KB
patch
obsolete
>From 674eb2642c8d48ae532005ee6d5b3138ffb2a763 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 15 Jun 2017 15:47:21 +0200 >Subject: [PATCH] Bug 18801: [Follow-up] Dbrev to repair bad auth type codes >Content-Type: text/plain; charset=utf-8 > >Test plan >Run updatedatabase. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > installer/data/mysql/atomicupdate/bug18801.perl | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug18801.perl > >diff --git a/installer/data/mysql/atomicupdate/bug18801.perl b/installer/data/mysql/atomicupdate/bug18801.perl >new file mode 100644 >index 0000000..8a8fd50 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug18801.perl >@@ -0,0 +1,15 @@ >+$DBversion = 'XXX'; # will be replaced by the RM >+if( CheckVersion( $DBversion ) ) { >+ # Fetch all auth types >+ my $authtypes = $dbh->selectcol_arrayref( q|SELECT authtypecode FROM auth_types| ); >+ >+ if( grep { $_ eq 'Default' } @$authtypes ) { >+ # If this exists as an authtypecode, we don't do anything >+ } else { >+ # Replace the incorrect Default by empty string >+ $dbh->do( q|UPDATE auth_header SET authtypecode='' WHERE authtypecode='Default'| ); >+ } >+ >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 18801 - Update incorrect Default auth type codes)\n"; >+} >-- >2.1.4
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 18801
:
64282
|
64303
| 64325