Check valid DOMElement existance before accessing it while updating the
menu updation.pull/3/head
parent
60208b7ae5
commit
bf042d46a2
|
|
@ -75,12 +75,12 @@ function(_, S, pgAdmin, $) {
|
|||
*/
|
||||
update: function(node, item) {
|
||||
|
||||
if (!this.$el.hasClass('disabled')) {
|
||||
if (this.$el && !this.$el.hasClass('disabled')) {
|
||||
this.$el.addClass('disabled');
|
||||
}
|
||||
|
||||
this.is_disabled = this.disabled(node, item);
|
||||
if (!this.is_disabled) {
|
||||
if (this.$el && !this.is_disabled) {
|
||||
this.$el.removeClass('disabled');
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue