From 66728fb1367cf9f23fcad30405cc8b4aa87fe0b0 Mon Sep 17 00:00:00 2001 From: Hannes Mannerheim Date: Tue, 29 Sep 2015 17:05:20 +0200 Subject: [PATCH] remove old error messages on stream change --- js/dom-functions.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/js/dom-functions.js b/js/dom-functions.js index fd12168..7941874 100644 --- a/js/dom-functions.js +++ b/js/dom-functions.js @@ -521,13 +521,14 @@ function setNewCurrentStream(streamObject,setLocation,fallbackId,actionOnSuccess return; } + // remove any old error messages + $('.error-message').remove(); + // remember state of old stream (including profile card) if(typeof window.currentStreamObject != 'undefined') { localStorageObjectCache_STORE('streamState',window.currentStreamObject.path, $('#feed').siblings('.profile-card').outerHTML() + $('#feed').outerHTML()); } - // window.oldStreams[window.currentStream] = $('#feed').siblings('.profile-card').outerHTML() + $('#feed').outerHTML(); - // halt interval that checks for new queets window.clearInterval(checkForNewQueetsInterval);