forked from Supositware/Haha-Yes
Fix join/leave message
This commit is contained in:
parent
e1c6c9dc39
commit
118954f795
1 changed files with 3 additions and 1 deletions
|
@ -1,6 +1,8 @@
|
||||||
import fs from 'node:fs';
|
import fs from 'node:fs';
|
||||||
export function rand(text, interaction) {
|
export function rand(text, interaction) {
|
||||||
|
if (interaction) {
|
||||||
interaction.author = interaction.user;
|
interaction.author = interaction.user;
|
||||||
|
}
|
||||||
// Find a value in an array of objects in Javascript - https://stackoverflow.com/a/12462387
|
// Find a value in an array of objects in Javascript - https://stackoverflow.com/a/12462387
|
||||||
function search(nameKey, myArray) {
|
function search(nameKey, myArray) {
|
||||||
for (let i = 0; i < myArray.length; i++) {
|
for (let i = 0; i < myArray.length; i++) {
|
||||||
|
|
Loading…
Reference in a new issue