Skip to content

Commit

Permalink
Fix add log entry route
Browse files Browse the repository at this point in the history
  • Loading branch information
nicou committed Jun 28, 2024
1 parent 3f0d7ee commit 848b05d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/routes/log.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ router.put('/', handleAsyncErrors(async (req, res) => {
if (!logEntry) {
logEntry = await LogEntry.forge().save(req.body, { method: 'insert' });
const message = logEntry.get('message');
if (typeof message === 'string' && message.toLowerCase().contains('incoming jump into current sector')) {
if (typeof message === 'string' && message.toLowerCase().includes('incoming jump into current sector')) {
dmx.fireEvent(dmx.CHANNELS.IncomingJumpWarning);
}
} else {
Expand Down

0 comments on commit 848b05d

Please sign in to comment.