X-Git-Url: https://git.cyclocoop.org/?a=blobdiff_plain;f=maintenance%2Finstall-utils.inc;h=e37aeb9f7c819fe5e34d24dc9612f2b2c720d43f;hb=5cd45f79d1b9164e87040da8d9a204e19fa2938b;hp=f865aca326235c184a26561e5f426d5d92869fb6;hpb=e64dde7a75d65df77e4361d4c09e75bf0807c78f;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/install-utils.inc b/maintenance/install-utils.inc index f865aca326..e37aeb9f7c 100644 --- a/maintenance/install-utils.inc +++ b/maintenance/install-utils.inc @@ -180,14 +180,7 @@ function readlineEmulation( $prompt ) { function dbsource( $fname, $db = false ) { wfDeprecated( __METHOD__ ); if ( !$db ) { - // Try $wgDatabase, which is used in the install and update scripts - global $wgDatabase; - if ( isset( $wgDatabase ) ) { - $db = $wgDatabase; - } else { - // No? Well, we must be outside of those scripts, so use the standard method - $db = wfGetDB( DB_MASTER ); - } + $db = wfGetDB( DB_MASTER ); } $error = $db->sourceFile( $fname ); if ( $error !== true ) { @@ -196,19 +189,9 @@ function dbsource( $fname, $db = false ) { } } -/** - * Helper function: check if the given key is present in the updatelog table. - * Obviously, only use this for updates that occur after the updatelog table was - * created! - */ -function update_row_exists( $key ) { - $row = wfGetDB( DB_MASTER )->selectRow( - 'updatelog', - '1', - array( 'ul_key' => $key ), - __FUNCTION__ - ); - return (bool)$row; +function archive( $name ) { + wfDeprecated( __METHOD__ ); + return DatabaseBase::patchPath( $name ); } /**