Index: trunk/phase3/includes/Export.php |
— | — | @@ -130,7 +130,7 @@ |
131 | 131 | public function pageByName( $name ) { |
132 | 132 | $title = Title::newFromText( $name ); |
133 | 133 | if( is_null( $title ) ) { |
134 | | - return new WikiError( "Can't export invalid title" ); |
| 134 | + throw new MWException( "Can't export invalid title" ); |
135 | 135 | } else { |
136 | 136 | return $this->pageByTitle( $title ); |
137 | 137 | } |
— | — | @@ -251,12 +251,12 @@ |
252 | 252 | # One, and only one hook should set this, and return false |
253 | 253 | if( wfRunHooks( 'WikiExporter::dumpStableQuery', array(&$tables,&$opts,&$join) ) ) { |
254 | 254 | wfProfileOut( __METHOD__ ); |
255 | | - return new WikiError( __METHOD__." given invalid history dump type." ); |
| 255 | + throw new MWException( __METHOD__." given invalid history dump type." ); |
256 | 256 | } |
257 | 257 | } else { |
258 | 258 | # Uknown history specification parameter? |
259 | 259 | wfProfileOut( __METHOD__ ); |
260 | | - return new WikiError( __METHOD__." given invalid history dump type." ); |
| 260 | + throw new MWException( __METHOD__." given invalid history dump type." ); |
261 | 261 | } |
262 | 262 | # Query optimization hacks |
263 | 263 | if( $cond == '' ) { |