rem: SimileAjax.History._iframe.contentDocument.title = SimileAjax.History.formatHistoryEntryTitle( SimileAjax.History._actions[this._currentIndex - this._baseIndex].label);  
add: if (SimileAjax.History._actions.length > 0) { SimileAjax.History._iframe.contentDocument.title = SimileAjax.History.formatHistoryEntryTitle( SimileAjax.History._actions[SimileAjax.History._currentIndex - SimileAjax.History._baseIndex].label); } 
context: SimileAjax.History._handleIFrameOnLoad = function() {    /*     *  This function is invoked when the user herself     *  navigates backward or forward. We need to adjust     *  the application's state accordingly.     */         var q = SimileAjax.History._iframe.contentWindow.location.search;    var c = (q.length == 0) ? 0 : Math.max(0, parseInt(q.substr(1)));        if (c < this._currentIndex) { // need to undo        SimileAjax.History._fire("onBeforeUndoSeveral", []);                while (SimileAjax.History._currentIndex > c &&                SimileAjax.History._currentIndex > SimileAjax.History._baseIndex) {                           SimileAjax.History._currentIndex--;                        var action = SimileAjax.History._actions[SimileAjax.History._currentIndex - SimileAjax.History._baseIndex];                        SimileAjax.History._fire("onBeforeUndo", [ action ]);            try {                action.undo();                SimileAjax.History._fire("onAfterUndo", [ action, true ]);            } catch (e) {                SimileAjax.History._fire("onAfterUndo", [ action, false ]);            }        }                SimileAjax.History._fire("onAfterUndoSeveral", []);            } else if (c > SimileAjax.History._currentIndex) { // need to redo        SimileAjax.History._fire("onBeforeRedoSeveral", []);                while (SimileAjax.History._currentIndex < c &&                SimileAjax.History._currentIndex - SimileAjax.History._baseIndex < SimileAjax.History._actions.length) {                           var action = SimileAjax.History._actions[this._currentIndex - this._baseIndex];                        SimileAjax.History._fire("onBeforeRedo", [ action ]);            try {                action.perform();                SimileAjax.History._fire("onAfterRedo", [ action, true ]);            } catch (e) {                SimileAjax.History._fire("onAfterRedo", [ action, false ]);            }                        SimileAjax.History._currentIndex++;        }                SimileAjax.History._fire("onAfterRedoSeveral", []);    } else {        SimileAjax.History._iframe.contentDocument.title =             SimileAjax.History.formatHistoryEntryTitle(                SimileAjax.History._actions[this._currentIndex - this._baseIndex].label);                    return;    }        var diff = c - SimileAjax.History._currentIndex;    SimileAjax.History._currentIndex += diff;    SimileAjax.History._baseIndex += diff;            SimileAjax.History._iframe.contentWindow.location.search = "?" + c;};
meta: 6194	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/6194/6b9c9a1223dcd49e046ac37241609e6248667b71/history.js/clean/src/webapp/api/scripts/history.js