Commit ad34e940 by 冷斌

fix bug

parent f8e331b5
......@@ -423,7 +423,7 @@
let item = localStorage.getItem("search");
console.log(item);
//['考研课程', '事业单位考试', '公务员考试'];
let data = item.length > 0 ? item : [];
let data = item ? item : [];
console.log(data);
if (data.indexOf(this.keyword) < 0) {
data.push(this.keyword);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment