We have already have a printable flag in the OutputPage object, so use it.
authorAlexandre Emsenhuber <ialex@users.mediawiki.org>
Fri, 18 Feb 2011 11:55:11 +0000 (11:55 +0000)
committerAlexandre Emsenhuber <ialex@users.mediawiki.org>
Fri, 18 Feb 2011 11:55:11 +0000 (11:55 +0000)
This was causing to have the printable version for every non-empty version of the printable paramter, instead of only for "yes".

includes/OutputPage.php

index f03e0e9..1ee62c0 100644 (file)
@@ -2411,7 +2411,7 @@ class OutputPage {
                        'only' => $only,
                );
                // Propagate printable and handheld parameters if present
-               if ( $wgRequest->getBool( 'printable' ) ) {
+               if ( $this->isPrintable() ) {
                        $query['printable'] = 1;
                }
                if ( $wgRequest->getBool( 'handheld' ) ) {