This commit is contained in:
parent
2f9b72a041
commit
359e2a1802
|
@ -9,7 +9,7 @@ const router = express.Router();
|
|||
router.get('/push', HandlePush);
|
||||
|
||||
router.get('/version', async (req, res) => {
|
||||
const {os_type} = res.query;
|
||||
const {os_type} = req.query;
|
||||
|
||||
try {
|
||||
const connection = await createDatabaseConnection(dbConfig);
|
||||
|
@ -24,7 +24,7 @@ router.get('/version', async (req, res) => {
|
|||
// const [rows] = await connection.query('SELECT * FROM version');
|
||||
const [rows] = await connection.query(query, queryParams);
|
||||
await connection.end();
|
||||
|
||||
|
||||
res.json(rows);
|
||||
} catch (err) {
|
||||
res.status(500).json({ error: err.message });
|
||||
|
|
Loading…
Reference in New Issue
Block a user