Fix undefined attrs.

This commit is contained in:
Guo Xiang Tan 2017-01-17 16:31:57 +08:00
parent ee58c4cd94
commit fc52624aac

View File

@ -226,7 +226,7 @@ export default createWidget('header', {
},
linkClickedEvent(attrs) {
if (!attrs.searchContextEnabled) this.closeAll();
if (!(attrs && attrs.searchContextEnabled)) this.closeAll();
this.updateHighlight();
},