mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-02 13:20:23 -05:00
add logging to tell us how long since a project that is being opened was last updated
This commit is contained in:
parent
c12213b46b
commit
417fd4f5f5
1 changed files with 3 additions and 1 deletions
|
@ -193,11 +193,13 @@ module.exports = ProjectController =
|
||||||
if err?
|
if err?
|
||||||
logger.err err:err, "error getting details for project page"
|
logger.err err:err, "error getting details for project page"
|
||||||
return next err
|
return next err
|
||||||
logger.log project_id:project_id, "got db results for loading editor"
|
|
||||||
project = results.project
|
project = results.project
|
||||||
user = results.user
|
user = results.user
|
||||||
subscription = results.subscription
|
subscription = results.subscription
|
||||||
|
|
||||||
|
daysSinceLastUpdated = (new Date() - project.lastUpdated) /86400000
|
||||||
|
logger.log project_id:project_id, daysSinceLastUpdated:daysSinceLastUpdated, "got db results for loading editor"
|
||||||
|
|
||||||
SecurityManager.userCanAccessProject user, project, (canAccess, privilegeLevel)->
|
SecurityManager.userCanAccessProject user, project, (canAccess, privilegeLevel)->
|
||||||
if !canAccess
|
if !canAccess
|
||||||
return res.sendStatus 401
|
return res.sendStatus 401
|
||||||
|
|
Loading…
Reference in a new issue