Skip to content

Commit

Permalink
Fix NPE in library events
Browse files Browse the repository at this point in the history
  • Loading branch information
shemanaev committed Jan 27, 2024
1 parent c1478b4 commit 3cff2e3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Jellyfin.Webhooks/EntryPoint.cs
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ private async Task ExecuteWebhook(EventInfo request)
.Where(h => h.Events.Contains(request.Event));
foreach (var hook in hooks)
{
if (!string.IsNullOrEmpty(hook.UserId) && request.User.Id.ToString("N") != hook.UserId)
if (!string.IsNullOrEmpty(hook.UserId) && request.User?.Id.ToString("N") != hook.UserId)
continue;

var formatter = _formatFactory.CreateFormat(hook.Format);
Expand Down
4 changes: 2 additions & 2 deletions Jellyfin.Webhooks/Jellyfin.Webhooks.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<RootNamespace>Jellyfin.Webhooks</RootNamespace>
<AssemblyVersion>3.6.0.0</AssemblyVersion>
<FileVersion>3.6.0.0</FileVersion>
<AssemblyVersion>3.6.1.0</AssemblyVersion>
<FileVersion>3.6.1.0</FileVersion>
</PropertyGroup>

<ItemGroup>
Expand Down
5 changes: 2 additions & 3 deletions build.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
name: "Webhooks"
guid: "eb5d7894-8eef-4b36-aa6f-5d124e828ce1"
version: "3.6.0.0"
version: "3.6.1.0"
targetAbi: "10.8.0.0"
framework: "net6.0"
overview: "Webhooks. Flexible and robust"
Expand All @@ -12,5 +12,4 @@ owner: "shemanaev"
artifacts:
- "Jellyfin.Webhooks.dll"
changelog: >
Add playback progress event
Add workaround for players that doesn't send stop event
Fix NPE in library events

0 comments on commit 3cff2e3

Please sign in to comment.