function deprecateConstant(obj, oldId, newId) {
        var warning     = "Use Menus." + newId + " instead of Menus." + oldId,
            newValue    = obj[newId];

        Object.defineProperty(obj, oldId, {
            get: function () {
                deprecationWarning(warning, true);
                return newValue;
            }
        });
    }
function deprecateConstant(obj, oldId, newId) {
        var warning     = "Use Menus." + newId + " instead of Menus." + oldId,
            newValue    = obj[newId];

        Object.defineProperty(obj, oldId, {
            get: function () {
                deprecationWarning(warning, true);
                return newValue;
            }
        });
    }
function deprecateConstant ( obj , oldId , newId ) { var warning = "Use Menus." + newId + " instead of Menus." + oldId , newValue = obj [ newId ] ; Object . defineProperty ( obj , oldId , { get : function ( ) { deprecationWarning ( warning , true ) ; return newValue ; } } ) ; }
Create a deprecation warning and action for updated constants
@param {!string} old Menu Id
@param {!string} new Menu Id
Create a deprecation warning and action for updated constants
Deprecate constant