update code
This commit is contained in:
aurik3
2022-10-25 10:12:00 -05:00
parent eaac1f1003
commit 7a3196625d
2 changed files with 2 additions and 1 deletions

1
api.js
View File

@@ -65,6 +65,7 @@ client.on("message", async (msg) => {
client.on("disconnected", () => { client.on("disconnected", () => {
console.log("disconnected"); console.log("disconnected");
}); });
client.initialize(); client.initialize();
const chatRoute = require("./components/chatting"); const chatRoute = require("./components/chatting");

View File

@@ -29,7 +29,7 @@ router.post('/sendmessage', async (req,res) => {
} }
}); });
router.post('/sendimage/:phone', async (req,res) => { router.post('/sendimage/', async (req,res) => {
var base64regex = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/; var base64regex = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/;
let phone = req.body.phone; let phone = req.body.phone;