tanishqgandhi1908 commented on code in PR #9226:
URL: https://github.com/apache/texera/pull/9226#discussion_r4596561962
##########
amber/src/main/scala/org/apache/texera/web/resource/dashboard/hub/HubResource.scala:
##########
@@ -418,7 +418,9 @@ class HubResource {
.returning(viewCountColumn)
.fetchOne()
- recordUserAction(request, userId, entityID, entityType, View)
+ // An anonymous viewer has no user row, so the view is recorded with a
NULL uid.
+ val viewerUid = Option(userId).filter(_.intValue() > 0).orNull
Review Comment:
recordUserAction now takes userId: Option[Integer] = None and sets the uid
only when present, the same way as the IP. postView passes
Option(userId).filter(_.intValue() > 0).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]