fix: 事件取消未判断空

This commit is contained in:
coding 2017-10-12 13:08:13 +00:00
parent 0b591bdb83
commit c3fa8bf3df

View File

@ -148,9 +148,12 @@ mapEventName();
module.exports = {
on: listen,
disable: function (jsp) {
var jspl = jspListener[jsp.description.name];
if (jspl) {
jspListener[jsp.description.name].forEach(function (t) {
t.off();
});
delete jspListener[jsp.description.name];
}
}
};