diff --git a/client/components/NetworkList.vue b/client/components/NetworkList.vue index 7de2e91b..cc0e0bdd 100644 --- a/client/components/NetworkList.vue +++ b/client/components/NetworkList.vue @@ -66,10 +66,7 @@ import NetworkLobby from "./NetworkLobby.vue"; import Channel from "./Channel.vue"; import JoinChannel from "./JoinChannel.vue"; -// TODO: ignoreSortSync should be removed -import {findChannel} from "../js/vue"; import socket from "../js/socket"; -// import options from "../js/options"; export default { name: "NetworkList", @@ -99,14 +96,13 @@ export default { type: "networks", order: this.networks.map((n) => n.uuid), }); - - // options.settings.ignoreSortSync = true; }, onChannelSort(e) { if (!e.moved) { return; } + const {findChannel} = require("../js/vue"); const channel = findChannel(e.moved.element.id); if (!channel) { @@ -118,8 +114,6 @@ export default { target: channel.network.uuid, order: channel.network.channels.map((c) => c.id), }); - - // options.settings.ignoreSortSync = true; }, }, }; diff --git a/client/js/socket-events/sync_sort.js b/client/js/socket-events/sync_sort.js index 8910cbf7..feaf45c1 100644 --- a/client/js/socket-events/sync_sort.js +++ b/client/js/socket-events/sync_sort.js @@ -2,15 +2,8 @@ const $ = require("jquery"); const socket = require("../socket"); -const options = require("../options"); socket.on("sync_sort", function(data) { - // Syncs the order of channels or networks when they are reordered - if (options.ignoreSortSync) { - options.ignoreSortSync = false; - return; // Ignore syncing because we 'caused' it - } - const type = data.type; const order = data.order; const container = $(".networks");