1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-10-30 07:22:35 +01:00

Fixed: API error when sending payload without optional parameters

Co-authored-by: Qstick <qstick@gmail.com>
This commit is contained in:
bakerboy448 2022-04-05 19:23:33 -05:00 committed by GitHub
parent 3be5d6c258
commit 8d83b1d8d6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -46,7 +46,10 @@ namespace Sonarr.Http.ClientSchema
var propertyType = mapping.PropertyType;
var field = fields.Find(f => f.Name == mapping.Field.Name);
mapping.SetterFunc(target, field.Value);
if (field != null)
{
mapping.SetterFunc(target, field.Value);
}
}
return target;