r46418 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r46417‎ | r46418 | r46419 >
Date:02:56, 28 January 2009
Author:werdna
Status:ok
Tags:
Comment:
Add some missing vars in the builder.
Modified paths:
  • /trunk/extensions/AbuseFilter/AbuseFilter.class.php (modified) (history)
  • /trunk/extensions/AbuseFilter/AbuseFilter.i18n.php (modified) (history)

Diff [purge]

Index: trunk/extensions/AbuseFilter/AbuseFilter.class.php
@@ -18,7 +18,7 @@
1919 'op-bool' => array( '!' => 'not', '&' => 'and', '|' => 'or', '^' => 'xor' ),
2020 'misc' => array( 'in' => 'in', 'like' => 'like', '""' => 'stringlit', ),
2121 'funcs' => array( 'length(string)' => 'length', 'lcase(string)' => 'lcase', 'ccnorm(string)' => 'ccnorm', 'rmdoubles(string)' => 'rmdoubles', 'specialratio(string)' => 'specialratio', 'norm(string)' => 'norm', 'count(needle,haystack)' => 'count' ),
22 - 'vars' => array( 'ACCOUNTNAME' => 'accountname', 'ACTION' => 'action', 'ADDED_LINES' => 'addedlines', 'EDIT_DELTA' => 'delta', 'EDIT_DIFF' => 'diff', 'NEW_SIZE' => 'newsize', 'OLD_SIZE' => 'oldsize', 'REMOVED_LINES' => 'removedlines', 'SUMMARY' => 'summary', 'ARTICLE_ARTICLEID' => 'article-id', 'ARTICLE_NAMESPACE' => 'article-ns', 'ARTICLE_TEXT' => 'article-text', 'ARTICLE_PREFIXEDTEXT' => 'article-prefixedtext', 'MOVED_FROM_ARTICLEID' => 'movedfrom-id', 'MOVED_FROM_NAMESPACE' => 'movedfrom-ns', 'MOVED_FROM_TEXT' => 'movedfrom-text', 'MOVED_FROM_PREFIXEDTEXT' => 'movedfrom-prefixedtext', 'MOVED_TO_ARTICLEID' => 'movedto-id', 'MOVED_TO_NAMESPACE' => 'movedto-ns', 'MOVED_TO_TEXT' => 'movedto-text', 'MOVED_TO_PREFIXEDTEXT' => 'movedto-prefixedtext', 'USER_EDITCOUNT' => 'user-editcount', 'USER_AGE' => 'user-age', 'USER_NAME' => 'user-name', 'USER_GROUPS' => 'user-groups', 'USER_EMAILCONFIRM' => 'user-emailconfirm', 'OLD_TEXT' => 'old-text', 'NEW_TEXT' => 'new-text'),
 22+ 'vars' => array( 'ACCOUNTNAME' => 'accountname', 'ACTION' => 'action', 'ADDED_LINES' => 'addedlines', 'EDIT_DELTA' => 'delta', 'EDIT_DIFF' => 'diff', 'NEW_SIZE' => 'newsize', 'OLD_SIZE' => 'oldsize', 'REMOVED_LINES' => 'removedlines', 'SUMMARY' => 'summary', 'ARTICLE_ARTICLEID' => 'article-id', 'ARTICLE_NAMESPACE' => 'article-ns', 'ARTICLE_TEXT' => 'article-text', 'ARTICLE_PREFIXEDTEXT' => 'article-prefixedtext', 'MOVED_FROM_ARTICLEID' => 'movedfrom-id', 'MOVED_FROM_NAMESPACE' => 'movedfrom-ns', 'MOVED_FROM_TEXT' => 'movedfrom-text', 'MOVED_FROM_PREFIXEDTEXT' => 'movedfrom-prefixedtext', 'MOVED_TO_ARTICLEID' => 'movedto-id', 'MOVED_TO_NAMESPACE' => 'movedto-ns', 'MOVED_TO_TEXT' => 'movedto-text', 'MOVED_TO_PREFIXEDTEXT' => 'movedto-prefixedtext', 'USER_EDITCOUNT' => 'user-editcount', 'USER_AGE' => 'user-age', 'USER_NAME' => 'user-name', 'USER_GROUPS' => 'user-groups', 'USER_EMAILCONFIRM' => 'user-emailconfirm', 'OLD_WIKITEXT' => 'old-text', 'NEW_WIKITEXT' => 'new-text', 'ADDED_LINKS' => 'added-links', 'REMOVED_LINKS' => 'removed-links', 'ALL_LINKS' => 'all-links', 'NEW_TEXT' => 'new-text-stripped', 'NEW_HTML' => 'new-html'),
2323 );
2424
2525 public static function generateUserVars( $user ) {
Index: trunk/extensions/AbuseFilter/AbuseFilter.i18n.php
@@ -237,8 +237,13 @@
238238 'abusefilter-edit-builder-vars-all-links' => 'All external links in the new text',
239239 'abusefilter-edit-builder-vars-added-links' => 'All external links added in the edit',
240240 'abusefilter-edit-builder-vars-removed-links' => 'All external links removed in the edit',
241 - 'abusefilter-edit-builder-vars-old-text' => 'Old page text, before the edit',
242 - 'abusefilter-edit-builder-vars-new-text' => 'New page text, after the edit',
 241+ 'abusefilter-edit-builder-vars-old-text' => 'Old page wikitext, before the edit',
 242+ 'abusefilter-edit-builder-vars-new-text' => 'New page wikitext, after the edit',
 243+ 'abusefilter-edit-builder-vars-new-text-stripped' => 'New page text, stripped of any markup',
 244+ 'abusefilter-edit-builder-vars-new-html' => 'Parsed HTML source of the new revision',
 245+ 'abusefilter-edit-builder-vars-all-links' => 'All links in the new page text',
 246+ 'abusefilter-edit-builder-vars-added-links' => 'Links added to the page',
 247+ 'abusefilter-edit-builder-vars-removed-links' => 'Links removed from the page',
243248
244249 // Filter history
245250 'abusefilter-filter-log' => 'Recent filter changes',

Status & tagging log