[[Special:Contributions]] with no target causes PHP errors.
authorRiver Tarnell <river@users.mediawiki.org>
Wed, 7 Mar 2007 22:22:04 +0000 (22:22 +0000)
committerRiver Tarnell <river@users.mediawiki.org>
Wed, 7 Mar 2007 22:22:04 +0000 (22:22 +0000)
Notice:  Undefined index:  target in /var/www/html/wiki-pg/includes/SpecialContributions.php on line 391
Notice:  Undefined index:  namespace in /var/www/html/wiki-pg/includes/SpecialContributions.php on line 393

includes/SpecialContributions.php

index c5ad25a..0d2f423 100644 (file)
@@ -378,6 +378,10 @@ function contributionsForm( $options ) {
        global $wgScript, $wgTitle;
 
        $options['title'] = $wgTitle->getPrefixedText();
+       if (!isset($options['target']))
+               $options['target'] = '';
+       if (!isset($options['namespace']))
+               $options['namespace'] = 0;
 
        $f = Xml::openElement( 'form', array( 'method' => 'get', 'action' => $wgScript ) );