private $mDependantParameters = array();
/**
- * Used by getDD() / setDB()
+ * Used by getDB() / setDB()
* @var DatabaseBase
*/
private $mDb = null;
global $wgProfiler;
$output = $this->getOption( 'profiler' );
- if ( $output && is_array( $wgProfiler ) ) {
+ if ( $output && is_array( $wgProfiler ) && isset( $wgProfiler['class'] ) ) {
$class = $wgProfiler['class'];
$profiler = new $class(
array( 'sampling' => 1, 'output' => $output ) + $wgProfiler
$wgShowSQLErrors = true;
- // @codingStandardsIgnoreStart Allow error supppression. wfSuppressWarnings()
- // is not avaiable.
+ // @codingStandardsIgnoreStart Allow error suppression. wfSuppressWarnings()
+ // is not available.
@set_time_limit( 0 );
// @codingStandardsIgnoreStart
*
* @return DatabaseBase
*/
- protected function &getDB( $db, $groups = array(), $wiki = false ) {
+ protected function getDB( $db, $groups = array(), $wiki = false ) {
if ( is_null( $this->mDb ) ) {
return wfGetDB( $db, $groups, $wiki );
} else {
*
* @param DatabaseBase $db Database object to be used
*/
- public function setDB( &$db ) {
+ public function setDB( $db ) {
$this->mDb = $db;
}
* Lock the search index
* @param DatabaseBase &$db
*/
- private function lockSearchindex( &$db ) {
+ private function lockSearchindex( $db ) {
$write = array( 'searchindex' );
$read = array( 'page', 'revision', 'text', 'interwiki', 'l10n_cache', 'user' );
$db->lockTables( $read, $write, __CLASS__ . '::' . __METHOD__ );
* Unlock the tables
* @param DatabaseBase &$db
*/
- private function unlockSearchindex( &$db ) {
+ private function unlockSearchindex( $db ) {
$db->unlockTables( __CLASS__ . '::' . __METHOD__ );
}
* Since the lock is low-priority, queued reads will be able to complete
* @param DatabaseBase &$db
*/
- private function relockSearchindex( &$db ) {
+ private function relockSearchindex( $db ) {
$this->unlockSearchindex( $db );
$this->lockSearchindex( $db );
}
* We default as considering stdin a tty (for nice readline methods)
* but treating stout as not a tty to avoid color codes
*
- * @param int $fd File descriptor
+ * @param mixed $fd File descriptor
* @return bool
*/
public static function posix_isatty( $fd ) {
}
/**
- * Message to show the the update log was unable to log the completion of this update
+ * Message to show that the update log was unable to log the completion of this update
* @return string
*/
protected function updatelogFailedMessage() {