Activity email links force new login

Steps to reproduce

  1. Enable activity emails
  2. Receive an activity email containing private links
  3. Click on a link

Expected behaviour

If you are logged and have permissions, system just should open the link and show you the files.

Actual behaviour

Opened sessions is closed and you are requested to log in again.