Merge pull request #10368 from 2403905/issue-10293

Disable download activity
This commit is contained in:
Roman Perekhod
2024-10-23 10:04:10 +02:00
committed by GitHub
2 changed files with 12 additions and 5 deletions

View File

@@ -0,0 +1,6 @@
Bugfix: Disable download activity
We disable the download activity until we have a proper solution for it.
https://github.com/owncloud/ocis/pull/10367
https://github.com/owncloud/ocis/issues/10293

View File

@@ -103,11 +103,12 @@ func (a *ActivitylogService) Run() {
err = a.AddActivity(ev.FileRef, e.ID, utils.TSToTime(ev.Timestamp))
case events.FileTouched:
err = a.AddActivity(ev.Ref, e.ID, utils.TSToTime(ev.Timestamp))
case events.FileDownloaded:
// we are only interested in public link downloads - so no need to store others.
if ev.ImpersonatingUser.GetDisplayName() == "Public" {
err = a.AddActivity(ev.Ref, e.ID, utils.TSToTime(ev.Timestamp))
}
// Disabled https://github.com/owncloud/ocis/issues/10293
//case events.FileDownloaded:
// we are only interested in public link downloads - so no need to store others.
//if ev.ImpersonatingUser.GetDisplayName() == "Public" {
// err = a.AddActivity(ev.Ref, e.ID, utils.TSToTime(ev.Timestamp))
//}
case events.ContainerCreated:
err = a.AddActivity(ev.Ref, e.ID, utils.TSToTime(ev.Timestamp))
case events.ItemTrashed: