mw.log.deprecate: Simplify warning message
authorTimo Tijhof <krinklemail@gmail.com>
Fri, 28 Feb 2014 20:03:28 +0000 (21:03 +0100)
committerTimo Tijhof <krinklemail@gmail.com>
Fri, 28 Feb 2014 20:03:28 +0000 (21:03 +0100)
* Remove odd MWDeprecationWarning prefix.
* Don't mention "property". All accessors targets are properties
  and saying so doesn't add much value (some of the targets are
  more thought of as constructors or methods), the name should
  be sufficient.

Change-Id: Ifc77d176fa830feccf13350b4fd9dbf8cb8d8046

resources/mediawiki/mediawiki.js

index 8b78370..4b11bd4 100644 (file)
@@ -558,8 +558,7 @@ var mw = ( function ( $, undefined ) {
                        log.deprecate = !Object.defineProperty ? function ( obj, key, val ) {
                                obj[key] = val;
                        } : function ( obj, key, val, msg ) {
-                               msg = 'MWDeprecationWarning: Use of "' + key + '" property is deprecated.' +
-                                       ( msg ? ( ' ' + msg ) : '' );
+                               msg = 'Use of "' + key + '" is deprecated.' + ( msg ? ( ' ' + msg ) : '' );
                                try {
                                        Object.defineProperty( obj, key, {
                                                configurable: true,