mirror of
https://github.com/Myxelium/RandomMemerBot.git
synced 2026-04-13 18:40:36 +00:00
Added join button for manully triggering the bot
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { nextPlayBackTime } from './../bot';
|
||||
import { joinRandomChannel, nextPlayBackTime } from './../bot';
|
||||
import express from 'express';
|
||||
import multer, { diskStorage } from 'multer';
|
||||
import path from 'path';
|
||||
@@ -149,6 +149,11 @@ app.delete('/sounds/:filename', (req, res) => {
|
||||
|
||||
app.use(express.static(path.join(__dirname, "web")));
|
||||
|
||||
app.get('/join', (_req, res) => {
|
||||
joinRandomChannel();
|
||||
res.send('Joining random channel.');
|
||||
});
|
||||
|
||||
/**
|
||||
* Starts the web server on either http or https protocol based on the availability of SSL certificates.
|
||||
* @returns void
|
||||
|
||||
Reference in New Issue
Block a user