mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Fixed a minor issue when trying to destroy a non existing drag_api
This commit is contained in:
9
dist/jquery.gridster.js
vendored
9
dist/jquery.gridster.js
vendored
@@ -3236,11 +3236,12 @@
|
||||
*/
|
||||
fn.destroy = function(){
|
||||
// remove bound callback on window resize
|
||||
$(window).unbind('resize', this.resize_callback);
|
||||
|
||||
// TODO: remove draggable bindings
|
||||
this.drag_api.destroy();
|
||||
$(window).unbind('resize', this.on_window_resize);
|
||||
|
||||
if(this.drag_api){
|
||||
this.drag_api.destroy();
|
||||
}
|
||||
|
||||
// lastly, remove gridster element
|
||||
// this will additionally cause any data associated to this element to be removed, including this
|
||||
// very gridster instance
|
||||
|
2
dist/jquery.gridster.min.js
vendored
2
dist/jquery.gridster.min.js
vendored
File diff suppressed because one or more lines are too long
9
dist/jquery.gridster.with-extras.js
vendored
9
dist/jquery.gridster.with-extras.js
vendored
@@ -3236,11 +3236,12 @@
|
||||
*/
|
||||
fn.destroy = function(){
|
||||
// remove bound callback on window resize
|
||||
$(window).unbind('resize', this.resize_callback);
|
||||
|
||||
// TODO: remove draggable bindings
|
||||
this.drag_api.destroy();
|
||||
$(window).unbind('resize', this.on_window_resize);
|
||||
|
||||
if(this.drag_api){
|
||||
this.drag_api.destroy();
|
||||
}
|
||||
|
||||
// lastly, remove gridster element
|
||||
// this will additionally cause any data associated to this element to be removed, including this
|
||||
// very gridster instance
|
||||
|
2
dist/jquery.gridster.with-extras.min.js
vendored
2
dist/jquery.gridster.with-extras.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -2531,9 +2531,10 @@
|
||||
// remove bound callback on window resize
|
||||
$(window).unbind('resize', this.on_window_resize);
|
||||
|
||||
// TODO: remove draggable bindings
|
||||
this.drag_api.destroy();
|
||||
|
||||
if(this.drag_api){
|
||||
this.drag_api.destroy();
|
||||
}
|
||||
|
||||
// lastly, remove gridster element
|
||||
// this will additionally cause any data associated to this element to be removed, including this
|
||||
// very gridster instance
|
||||
|
Reference in New Issue
Block a user