@@ -46,7 +46,7 @@ public struct InPlayerItem : Codable {
46
46
case wowza( asset: WowzaAsset )
47
47
case unknown
48
48
}
49
-
49
+
50
50
/// Item's ID
51
51
public let id : Int ?
52
52
@@ -58,6 +58,8 @@ public struct InPlayerItem : Codable {
58
58
59
59
/// Shows whether the asset is active and can be monetized
60
60
public let isActive : Bool ?
61
+
62
+ public let active : Bool ?
61
63
62
64
/// The asset’s title
63
65
public let title : String ?
@@ -93,6 +95,7 @@ public struct InPlayerItem : Codable {
93
95
case createdAt = " created_at "
94
96
case id = " id "
95
97
case isActive = " is_active "
98
+ case active = " active "
96
99
case itemType = " item_type "
97
100
case merchantId = " merchant_id "
98
101
case merchantUuid = " merchant_uuid "
@@ -122,6 +125,7 @@ public struct InPlayerItem : Codable {
122
125
content = try values. decodeIfPresent ( String . self, forKey: . content)
123
126
templateId = try values. decodeIfPresent ( Int . self, forKey: . templateId)
124
127
ageRestriction = try values. decodeIfPresent ( InPlayerAgeRestriction . self, forKey: . ageRestriction)
128
+ active = try values. decodeIfPresent ( Bool . self, forKey: . active)
125
129
}
126
130
127
131
/// Encoder method
@@ -141,6 +145,7 @@ public struct InPlayerItem : Codable {
141
145
try values. encodeIfPresent ( content, forKey: . content)
142
146
try values. encodeIfPresent ( templateId, forKey: . templateId)
143
147
try values. encodeIfPresent ( ageRestriction, forKey: . ageRestriction)
148
+ try values. encodeIfPresent ( active, forKey: . active)
144
149
}
145
150
146
151
/// Method that return parsed content as enum with associated values
0 commit comments