Skip to content

Commit f7bec8a

Browse files
glpatcernYukaii
andauthored
Better update of the authorship of anonymous users
Co-authored-by: Yukai Huang <yukaihuangtw@gmail.com>
1 parent c9399f3 commit f7bec8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/note/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ const updateNote = async (req, res) => {
294294
lastchangeAt: now,
295295
authorship: req.isAuthenticated() ? [
296296
[
297-
req.user.id,
297+
req.isAuthenticated() ? req.user.id : null,
298298
0,
299299
content.length,
300300
now,

0 commit comments

Comments
 (0)