Index: trunk/extensions/SpamBlacklist/SpamBlacklist.php |
— | — | @@ -80,10 +80,10 @@ |
81 | 81 | /** |
82 | 82 | * Hook function for EditFilterMerged, replaces wfSpamBlacklistFilter |
83 | 83 | */ |
84 | | -function wfSpamBlacklistFilterMerged( $editPage, $text, &$hookErr, $editSummary ) { |
| 84 | +function wfSpamBlacklistFilterMerged( &$editPage, $text, &$hookErr, $editSummary ) { |
85 | 85 | $spamObj = wfSpamBlacklistObject(); |
86 | 86 | $title = $editPage->mArticle->getTitle(); |
87 | | - $ret = $spamObj->filter( $title, $text, '', $editPage, $editSummary ); |
| 87 | + $ret = $spamObj->filter( $title, $text, '', $editSummary, $editPage ); |
88 | 88 | // Return convention for hooks is the inverse of $wgFilterCallback |
89 | 89 | return !$ret; |
90 | 90 | } |
Index: trunk/extensions/SpamBlacklist/SpamBlacklist_body.php |
— | — | @@ -184,12 +184,12 @@ |
185 | 185 | * @param Title $title |
186 | 186 | * @param string $text Text of section, or entire text if $editPage!=false |
187 | 187 | * @param string $section Section number or name |
188 | | - * @param EditPage $editPage EditPage if EditFilterMerged was called, false otherwise |
189 | 188 | * @param EditSummary $editSummary Edit summary if one exists, some people use urls there too |
| 189 | + * @param EditPage $editPage EditPage if EditFilterMerged was called, null otherwise |
190 | 190 | * @return True if the edit should not be allowed, false otherwise |
191 | 191 | * If the return value is true, an error will have been sent to $wgOut |
192 | 192 | */ |
193 | | - function filter( &$title, $text, $section, $editPage = false, $editsummary = '' ) { |
| 193 | + function filter( &$title, $text, $section, $editsummary = '', EditPage &$editPage = null ) { |
194 | 194 | global $wgArticle, $wgVersion, $wgOut, $wgParser, $wgUser; |
195 | 195 | |
196 | 196 | $fname = 'wfSpamBlacklistFilter'; |