nextcloud / forms

📝 Simple form & survey app for Nextcloud
https://apps.nextcloud.com/apps/forms
GNU Affero General Public License v3.0
316 stars 97 forks source link

fix: DI `userId` instead of `userSession` #2293

Closed susnux closed 1 month ago

susnux commented 1 month ago

The ActivityManager only needs the user ID so we just can inject the userId. Also make sure that it can be null, because the ActivityManager is DI in the FormsService and the FormsService is used also for public forms where no user is logged in.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 87.50000% with 1 line in your changes missing coverage. Please review.

Please upload report for BASE (main@e9e6701). Learn more about missing BASE report. Report is 4 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #2293 +/- ## ======================================= Coverage ? 45.03% Complexity ? 814 ======================================= Files ? 68 Lines ? 3073 Branches ? 0 ======================================= Hits ? 1384 Misses ? 1689 Partials ? 0 ```
nickvergessen commented 1 month ago

Config service has a similar issue, didn't check open PRs before sending https://github.com/nextcloud/forms/pull/2294

Chartman123 commented 1 month ago

Config service has a similar issue, didn't check open PRs before sending #2294

Yes, we're already aware... 🙂 Perhaps @susnux can fix it already, otherwise I'll have a look at it this evening.

susnux commented 1 month ago

Fix is included now