Skip to content

Commit

Permalink
fix to send chat messages without options
Browse files Browse the repository at this point in the history
  • Loading branch information
zfbx committed Dec 9, 2021
1 parent a5c40b1 commit 0a9de0e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions server/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ exports.sendStaffChatMessage = sendStaffChatMessage;
* @param {string} msg - message to send
* @param {object} options - options: array color[r, g, b], bool multiline */
const chatMessage = (destination, label, msg, options) => {
if (!options) { options = {}; }
TriggerClientEvent("chat:addMessage", destination, {
color: (options.color || [ 255, 255, 255 ]),
multiline: options.multiline || false,
Expand Down

0 comments on commit 0a9de0e

Please sign in to comment.