diff --git a/Sortable.js b/Sortable.js index 75365d7..d271999 100644 --- a/Sortable.js +++ b/Sortable.js @@ -23,6 +23,12 @@ } })(function () { "use strict"; + + if (typeof window == "undefined" || typeof window.document == "undefined") { + return function() { + throw new Error( "Sortable.js requires a window with a document" ); + } + } var dragEl, parentEl,