You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
257 B
JavaScript
21 lines
257 B
JavaScript
4 years ago
|
let uuids = [];
|
||
|
|
||
|
const get = (id) => {
|
||
|
if (uuids.indexOf(id) !== -1)
|
||
|
return true;
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
const push = (id) => {
|
||
|
uuids.push(id)
|
||
|
}
|
||
|
|
||
|
const pop = (id) => {
|
||
|
uuids = uuids.filter((x) => x !== id)
|
||
|
}
|
||
|
|
||
|
module.exports = {
|
||
|
get,
|
||
|
push,
|
||
|
pop
|
||
|
};
|