From 9279aea54aa90f5c9c61fb53dd49d725ee701fb8 Mon Sep 17 00:00:00 2001 From: jmal Date: Sat, 7 Nov 2020 23:45:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=EF=BC=9A=E7=BD=91=E7=AB=99?= =?UTF-8?q?=E4=B8=BB=E9=A1=B5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/public/articles/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/public/articles/index.vue b/src/views/public/articles/index.vue index 9c7b441..c36fc50 100644 --- a/src/views/public/articles/index.vue +++ b/src/views/public/articles/index.vue @@ -114,7 +114,7 @@ import { getSetting } from '@/api/user' let divTyping = document.getElementById('article-title') let i = 0,timer = 0,str = this.userSetting.backgroundTextSite function typing () { - if (i <= str.length) { + if (str && i <= str.length) { divTyping.innerHTML = str.slice(0, i++) timer = setTimeout(typing, 100) } else {