diff --git a/account/src/lib/couch-db.ts b/account/src/lib/couch-db.ts index 1114d56..041bb57 100644 --- a/account/src/lib/couch-db.ts +++ b/account/src/lib/couch-db.ts @@ -49,7 +49,6 @@ export async function getAllLingdocsUsers(): Promise { } export async function insertLingdocsUser(user: T.LingdocsUser): Promise { - console.log("coming to insert this user", user); const res = await usersDb.insert(user); const newUser = processAPIResponse(user, res); if (!newUser) { @@ -100,12 +99,12 @@ export async function updateLingdocsUser(uuid: T.UUID, toUpdate: } | { userTextOptionsRecord: T.UserTextOptionsRecord } | { upgradeToStudentRequest: "waiting" } | - { upgradeToStudentRequest: "denied" } | - { lastActive: T.TimeStamp } | + { upgradeToStudentRequest: "denied" } | { tests: T.TestResult[] } ): Promise { const user = await getLingdocsUser("userId", uuid); if (!user) throw new Error("unable to update - user not found " + uuid); + console.log("inUpdateLingdocsUser", toUpdate); if ("tests" in toUpdate) { const newTests = toUpdate.tests.filter((t) => !user.tests.some(x => x.time === t.time)); console.log("will try to add test");