Compare commits
No commits in common. "0870ac93521d4485af466c625b2a28bf7bcf577f" and "57b837cd601a253d4668bbcd6837a5aadb06ed6a" have entirely different histories.
0870ac9352
...
57b837cd60
|
|
@ -1,12 +1,12 @@
|
||||||
{
|
{
|
||||||
"name": "schat2-clive",
|
"name": "schat2-clive",
|
||||||
"version": "1.5.7",
|
"version": "1.5.6",
|
||||||
"lockfileVersion": 2,
|
"lockfileVersion": 2,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "schat2-clive",
|
"name": "schat2-clive",
|
||||||
"version": "1.5.7",
|
"version": "1.5.6",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"bhttp": "^1.2.8",
|
"bhttp": "^1.2.8",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "schat2-clive",
|
"name": "schat2-clive",
|
||||||
"version": "1.5.7",
|
"version": "1.5.6",
|
||||||
"description": "Game host for SChat 2-powered chat sites",
|
"description": "Game host for SChat 2-powered chat sites",
|
||||||
"main": "src/app.js",
|
"main": "src/app.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|
|
||||||
|
|
@ -1,17 +0,0 @@
|
||||||
'use strict';
|
|
||||||
|
|
||||||
function shuffle(unshuffled, limit = 10) {
|
|
||||||
const shuffled = unshuffled;
|
|
||||||
|
|
||||||
for (let i = shuffled.length - 1; i > 0; i -= 1) {
|
|
||||||
const j = Math.floor(Math.random() * (i + 1));
|
|
||||||
const temp = shuffled[i];
|
|
||||||
|
|
||||||
shuffled[i] = shuffled[j];
|
|
||||||
shuffled[j] = temp;
|
|
||||||
}
|
|
||||||
|
|
||||||
return shuffled.slice(0, limit);
|
|
||||||
}
|
|
||||||
|
|
||||||
module.exports = shuffle;
|
|
||||||
Loading…
Reference in New Issue