hardlounge/client/js/socket-events/sessions_list.ts

8 lines
192 B
TypeScript
Raw Permalink Normal View History

2019-11-16 17:24:03 +00:00
import socket from "../socket";
import {store} from "../store";
2017-08-15 09:44:29 +00:00
socket.on("sessions:list", function (data) {
2017-08-15 09:44:29 +00:00
data.sort((a, b) => b.lastUse - a.lastUse);
store.commit("sessions", data);
2017-08-15 09:44:29 +00:00
});