r102473 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r102472‎ | r102473 | r102474 >
Date:00:45, 9 November 2011
Author:neilk
Status:ok
Tags:
Comment:
typos in category methods -- error callbacks renamed
Modified paths:
  • /trunk/extensions/UploadWizard/resources/mw.Api.category.js (modified) (history)

Diff [purge]

Index: trunk/extensions/UploadWizard/resources/mw.Api.category.js
@@ -9,7 +9,7 @@
1010 * @param {Function} optional callback to run if api error
1111 * @return ajax call object
1212 */
13 - isCategory: function( title, callback, error ) {
 13+ isCategory: function( title, callback, err ) {
1414 var params = {
1515 'prop': 'categoryinfo',
1616 'titles': title.toString()
@@ -37,7 +37,7 @@
3838 * @param {Function} optional callback to run if api error
3939 * @return ajax call object
4040 */
41 - getCategoriesByPrefix: function( prefix, callback, error ) {
 41+ getCategoriesByPrefix: function( prefix, callback, err ) {
4242
4343 var params = {
4444 'list': 'allcategories',
@@ -65,9 +65,10 @@
6666 * @param {mw.Title}
6767 * @param {Function} callback to pass categories to (or false, if title not found)
6868 * @param {Function} optional callback to run if api error
 69+ * @param {Boolean} optional asynchronousness (default = true = async)
6970 * @return ajax call object
7071 */
71 - getCategories: function( title, callback, error, async ) {
 72+ getCategories: function( title, callback, err, async ) {
7273 var params = {
7374 prop: 'categories',
7475 titles: title.toString()

Status & tagging log