From 74fc2802ef485bb682184863f41f03fafe344d09 Mon Sep 17 00:00:00 2001 From: Chris Date: Fri, 16 Aug 2019 13:41:42 +0200 Subject: [PATCH] fixed silly bug --- web/js/opentrashmail.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/web/js/opentrashmail.js b/web/js/opentrashmail.js index a5d2643..f1a84a3 100644 --- a/web/js/opentrashmail.js +++ b/web/js/opentrashmail.js @@ -90,6 +90,8 @@ function updateEmailTable() if(Object.keys(data.emails).length>0) for(em in data.emails) { + if($("#nomailyet").length != 0) + $("#nomailyet").remove(); if(em>lastid) lastid = em; var date = new Date(parseInt(em)) var datestring = date.getDate()+"."+date.getMonth()+"."+date.getFullYear()+" "+date.getHours()+":"+date.getMinutes(); @@ -102,11 +104,10 @@ function updateEmailTable() '+ed.subject.toHtmlEntities()+'\ '); } - else if(lastid==0){ - console.log("leider keine post") + else if(lastid==0 && $("#nomailyet").length == 0){ $("#emailtable").append('\ - \ -

No emails received on this address (yet..)

\ + \ +

No emails received on this address (yet..)

\ '); } }