node-go/server/data/queries/game.js

23 lines
368 B
JavaScript
Raw Permalink Normal View History

2020-01-21 07:05:55 +00:00
const knex = require('../db');
const findGameById = async (gameId) => {
return await knex('game')
.where({'id': gameId})
.select('*');
}
const findGameByRoom = async (roomId) => {
return await knex('game')
.where({'id': roomId})
.select('*');
}
const insertGame = async (game) => {
}
module.exports = {
findGameById,
findGameByRoom,
insertGame
}