add await
This commit is contained in:
1 parent
9161c6d7db
commit
fb4474b44e
1 file changed
+1
-1
@@ -50,7 +50,7 @@ const saveToLog = async (source, text = '') => {
|
||||
let user = await db.query({text, values})
|
||||
let data = null
|
||||
if (user.rowCount === 0) {
|
||||
data = api.line.getUserInfo(groupId, userId)
|
||||
data = await api.line.getUserInfo(groupId, userId)
|
||||
console.log('user data ::::: ', data)
|
||||
if (data === null) {
|
||||
db.release()
|
||||
|
||||
Reference in new issue
Block a user