jellyfin / jellyfin-plugin-reports

Reports Plugin for Jellyfin
https://jellyfin.org
MIT License
30 stars 19 forks source link

Incorrect argument type passed to IUserManager.GetUserById #18

Closed oddstr13 closed 4 years ago

oddstr13 commented 4 years ago
Api/ReportsService.cs(111,94): error CS1503: Argument 1: cannot convert from 'string' to 'System.Guid' [/home/oddstr13/Projects/Jellyfin/Plugins/jellyfin-plugin-reports/Jellyfin.Plugin.Reports/Jellyfin.Plugin.Reports.csproj]
Api/ReportsService.cs(145,94): error CS1503: Argument 1: cannot convert from 'string' to 'System.Guid' [/home/oddstr13/Projects/Jellyfin/Plugins/jellyfin-plugin-reports/Jellyfin.Plugin.Reports/Jellyfin.Plugin.Reports.csproj]

IUserManager.GetUserById now takes Guid and not string.

Wrapping request.UserId in new Guid() makes the error go away, but I'm not sure if this is the correct way to do this.

https://github.com/jellyfin/jellyfin-plugin-reports/blob/8ffc8ba47d2f8c4a72cdd03322750e2daa46f868/Jellyfin.Plugin.Reports/Api/ReportsService.cs#L111 https://github.com/jellyfin/jellyfin-plugin-reports/blob/8ffc8ba47d2f8c4a72cdd03322750e2daa46f868/Jellyfin.Plugin.Reports/Api/ReportsService.cs#L145