index.js
function saveBoxed(onDoneCallback = UNDEFINED) {
    const boxed = this.boxed;
    if (boxed) {
        const modified = boxed[boxedImmutable.BOXED_GET_THIS].valueOfModified();
        if (modified !== UNDEFINED) {
            this.boxed = UNDEFINED;
            if (this.saveState) {
                return this.saveState(modified, boxed, onDoneCallback);
            } else {
                throw new TypeError("Save State Not Supported on this instance, saveState callback not provided");
            }
        }
    } else if (onDoneCallback) {
        onDoneCallback();
    }
}
function saveBoxed(onDoneCallback = UNDEFINED) {
    const boxed = this.boxed;
    if (boxed) {
        const modified = boxed[boxedImmutable.BOXED_GET_THIS].valueOfModified();
        if (modified !== UNDEFINED) {
            this.boxed = UNDEFINED;
            if (this.saveState) {
                return this.saveState(modified, boxed, onDoneCallback);
            } else {
                throw new TypeError("Save State Not Supported on this instance, saveState callback not provided");
            }
        }
    } else if (onDoneCallback) {
        onDoneCallback();
    }
}
function saveBoxed ( onDoneCallback = UNDEFINED ) { const boxed = this . boxed ; if ( boxed ) { const modified = boxed [ boxedImmutable . BOXED_GET_THIS ] . valueOfModified ( ) ; if ( modified !== UNDEFINED ) { this . boxed = UNDEFINED ; if ( this . saveState ) { return this . saveState ( modified , boxed , onDoneCallback ) ; } else { throw new TypeError ( "Save State Not Supported on this instance, saveState callback not provided" ) ; } } } else if ( onDoneCallback ) { onDoneCallback ( ) ; } }
save modified state
@param onDoneCallback    function to call on save complete
@return {*}
save modified state