Check we have some elements before creating a sortable
This commit is contained in:
parent
86ffcbb039
commit
5c29792d14
|
@ -112,11 +112,12 @@ class ResultsHandler {
|
||||||
__initializeResults() {
|
__initializeResults() {
|
||||||
this.results = document.querySelector('.results');
|
this.results = document.querySelector('.results');
|
||||||
|
|
||||||
const sortable = new Sortable(this.results, {
|
if (this.results) {
|
||||||
"onStart": this.__sortableActivate.bind(this),
|
const sortable = new Sortable(this.results, {
|
||||||
"onEnd": this.__sortableDeactivate.bind(this),
|
"onStart": this.__sortableActivate.bind(this),
|
||||||
// "forceFallback": true,
|
"onEnd": this.__sortableDeactivate.bind(this),
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
this.curating = false;
|
this.curating = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue