mirror of
https://github.com/overleaf/overleaf.git
synced 2025-01-23 05:42:55 +00:00
Use email if name is blank
This commit is contained in:
parent
960d1e8b2f
commit
dec9b5bf1e
1 changed files with 4 additions and 2 deletions
|
@ -415,6 +415,8 @@ define [
|
|||
thread.resolved_by_user = formatUser(thread.resolved_by_user)
|
||||
$scope.reviewPanel.resolvedThreadIds[thread_id] = true
|
||||
$scope.reviewPanel.commentThreads = threads
|
||||
$timeout () ->
|
||||
$scope.$broadcast "review-panel:layout"
|
||||
|
||||
formatComment = (comment) ->
|
||||
comment.user = formatUser(comment.user)
|
||||
|
@ -436,9 +438,9 @@ define [
|
|||
name = "You"
|
||||
isSelf = true
|
||||
else
|
||||
name = [user.first_name, user.last_name].filter((n) -> n?).join(" ")
|
||||
name = [user.first_name, user.last_name].filter((n) -> n? and n != "").join(" ")
|
||||
if name == ""
|
||||
name = "Unknown"
|
||||
name = user.email?.split("@")[0] or "Unknown"
|
||||
isSelf = false
|
||||
return {
|
||||
id: id
|
||||
|
|
Loading…
Reference in a new issue