Commit 9ccedbe4 authored by wty's avatar wty

后端代码错误处理更新5

parent 0a885662
......@@ -32,7 +32,7 @@ router.get('/getUser', function (req, res, next) {
}
console.log(result)
const _result = result.slice()
_result[0]?.follow = JSON.parse(_result[0].follow)
_result[0].follow = JSON.parse(_result[0].follow)
res.send({
success: true,
data: {
......@@ -53,7 +53,7 @@ router.get('/login', (req, res) => {
})
throw err
}
if (!!result && result[0]?.uid) {
if (!!result && result[0].uid) {
res.cookie('uid', result[0].uid)
res.send({
success: true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment