Ignore `Grabbed` with STJson

(cherry picked from commit cc5b5463f225604a29820e026a43d7dc33f0ffa5)

Closes #4824
pull/4862/head v2.4.0.4222
Bogdan 5 months ago
parent ceca76d7c0
commit 959f6be019

@ -1,9 +1,9 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text.Json.Serialization;
using Lidarr.Api.V1.Artist;
using Lidarr.Http.REST;
using Newtonsoft.Json;
using NzbDrone.Core.MediaCover;
using NzbDrone.Core.Music;
using Swashbuckle.AspNetCore.Annotations;
@ -49,7 +49,7 @@ namespace Lidarr.Api.V1.Albums
public string RemoteCover { get; set; }
// Hiding this so people don't think its usable (only used to set the initial state)
[JsonProperty(DefaultValueHandling = DefaultValueHandling.Ignore)]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
[SwaggerIgnore]
public bool Grabbed { get; set; }
}

@ -1,9 +1,9 @@
using System.Collections.Generic;
using System.Linq;
using System.Text.Json.Serialization;
using Lidarr.Api.V1.Artist;
using Lidarr.Api.V1.TrackFiles;
using Lidarr.Http.REST;
using Newtonsoft.Json;
using NzbDrone.Core.Music;
using Swashbuckle.AspNetCore.Annotations;
@ -29,7 +29,7 @@ namespace Lidarr.Api.V1.Tracks
public Ratings Ratings { get; set; }
// Hiding this so people don't think its usable (only used to set the initial state)
[JsonProperty(DefaultValueHandling = DefaultValueHandling.Ignore)]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
[SwaggerIgnore]
public bool Grabbed { get; set; }
}

Loading…
Cancel
Save