hardlounge/client/js/socket-events/sessions_list.js
2019-11-25 20:12:27 +02:00

9 lines
222 B
JavaScript

"use strict";
const socket = require("../socket");
const {vueApp} = require("../vue");
socket.on("sessions:list", function(data) {
data.sort((a, b) => b.lastUse - a.lastUse);
vueApp.$store.commit("sessions", data);
});