Index: trunk/extensions/UploadWizard/resources/mw.Utilities.js |
— | — | @@ -3,30 +3,29 @@ |
4 | 4 | ( function( mw ) { |
5 | 5 | |
6 | 6 | /** |
7 | | - * Check if a value is null, undefined, or the empty string. |
8 | | - * |
9 | | - * @param {Object} object Object to be checked |
10 | | - * @return {Boolean} |
11 | | - */ |
| 7 | + * Check if a value is null, undefined, or the empty string. |
| 8 | + * |
| 9 | + * @param {object} object Object to be checked |
| 10 | + * @return {boolean} |
| 11 | + */ |
12 | 12 | mw.isEmpty = function( o ) { |
13 | 13 | return ! mw.isDefined( o ) || o === null || ( typeof o === 'string' && o === '' ); |
14 | 14 | }; |
15 | 15 | |
16 | 16 | /** |
17 | 17 | * Check if something is defined |
18 | | - * (inlineable?) |
19 | | - * @param {Object} |
20 | | - * @return boolean |
| 18 | + * @param {object} |
| 19 | + * @return {boolean} |
21 | 20 | */ |
22 | | - mw.isDefined = function( obj ) { |
23 | | - return typeof obj !== 'undefined'; |
| 21 | + mw.isDefined = function( o ) { |
| 22 | + return typeof o !== 'undefined'; |
24 | 23 | }; |
25 | 24 | |
26 | 25 | |
27 | 26 | /** |
28 | 27 | * Upper-case the first letter of a string. |
29 | | - * @param string |
30 | | - * @return string with first letter uppercased. |
| 28 | + * @param {string} |
| 29 | + * @return {string} with first letter uppercased. |
31 | 30 | */ |
32 | 31 | mw.ucfirst = function( s ) { |
33 | 32 | return s.substring(0,1).toUpperCase() + s.substr(1); |