summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2018-12-21 12:03:34 +0100
committerBackportbot <backportbot-noreply@rullzer.com>2018-12-21 13:21:52 +0000
commitfaf7a1906f17e0ebaf76008e44b226cbe590ee6f (patch)
tree18084b833b88f0c2e3ca80f2c1cc076017acb787 /apps
parent01fa79d8d674b1588aac2fb889e6769854b95cf9 (diff)
downloadnextcloud-server-faf7a1906f17e0ebaf76008e44b226cbe590ee6f.tar.gz
nextcloud-server-faf7a1906f17e0ebaf76008e44b226cbe590ee6f.zip
Replace ChildNode.before with custom before helper
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps')
-rw-r--r--apps/files/js/navigation.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/apps/files/js/navigation.js b/apps/files/js/navigation.js
index db48775f0fb..8fa16f5da46 100644
--- a/apps/files/js/navigation.js
+++ b/apps/files/js/navigation.js
@@ -248,8 +248,11 @@
* This method allows easy swapping of elements.
*/
swap: function (list, j, i) {
- list[i].before(list[j]);
- list[j].before(list[i]);
+ var before = function(node, insertNode) {
+ node.parentNode.insertBefore(insertNode, node);
+ }
+ before(list[i], list[j]);
+ before(list[j], list[i]);
}
};