debugging

This commit is contained in:
lingdocs 2022-09-01 18:25:59 +04:00
parent e581005d21
commit 30b500230a
2 changed files with 2 additions and 0 deletions

View File

@ -49,6 +49,7 @@ export async function getAllLingdocsUsers(): Promise<T.LingdocsUser[]> {
}
export async function insertLingdocsUser(user: T.LingdocsUser): Promise<T.LingdocsUser> {
console.log("coming to insert this user", user);
const res = await usersDb.insert(user);
const newUser = processAPIResponse(user, res);
if (!newUser) {

View File

@ -51,6 +51,7 @@ apiRouter.put("/user/tests", async (req, res, next) => {
if (!req.user) return next("user not found");
try {
const { tests } = req.body as T.PostTestResultsBody;
console.log("will update with", tests);
await updateLingdocsUser(req.user.userId, { tests });
sendResponse(res, {
ok: true,