jalali-moment.js
function setDate(momentInstance, year, month, day) {
    var d = momentInstance._d;
    if (momentInstance._isUTC) {
        /*eslint-disable new-cap*/
        momentInstance._d = new Date(Date.UTC(year, month, day,
            d.getUTCHours(), d.getUTCMinutes(), d.getUTCSeconds(), d.getUTCMilliseconds()));
        /*eslint-enable new-cap*/
    } else {
        momentInstance._d = new Date(year, month, day,
            d.getHours(), d.getMinutes(), d.getSeconds(), d.getMilliseconds());
    }
}
function setDate(momentInstance, year, month, day) {
    var d = momentInstance._d;
    if (momentInstance._isUTC) {
        /*eslint-disable new-cap*/
        momentInstance._d = new Date(Date.UTC(year, month, day,
            d.getUTCHours(), d.getUTCMinutes(), d.getUTCSeconds(), d.getUTCMilliseconds()));
        /*eslint-enable new-cap*/
    } else {
        momentInstance._d = new Date(year, month, day,
            d.getHours(), d.getMinutes(), d.getSeconds(), d.getMilliseconds());
    }
}
function setDate ( momentInstance , year , month , day ) { var d = momentInstance . _d ; if ( momentInstance . _isUTC ) { /*eslint-disable new-cap*/ momentInstance . _d = new Date ( Date . UTC ( year , month , day , d . getUTCHours ( ) , d . getUTCMinutes ( ) , d . getUTCSeconds ( ) , d . getUTCMilliseconds ( ) ) ) ; /*eslint-enable new-cap*/ } else { momentInstance . _d = new Date ( year , month , day , d . getHours ( ) , d . getMinutes ( ) , d . getSeconds ( ) , d . getMilliseconds ( ) ) ; } }
set a gregorian date to moment object
@param {string} momentInstance
@param {string} year in gregorian system
@param {string} month in gregorian system
@param {string} day in gregorian system
set a gregorian date to moment object