Skip to content

Commit

Permalink
Update UserNotice.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
MahdiBM committed Nov 16, 2023
1 parent 65959a4 commit 33b2614
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions Sources/TwitchIRC/IncomingMessage/UserNotice.swift
Original file line number Diff line number Diff line change
Expand Up @@ -512,22 +512,26 @@ public struct UserNotice: MessageWithBadges {
public var category: String
public var id: String
public var value: UInt

public var copoReward: UInt

internal init(
category: String,
id: String,
value: UInt
value: UInt,
copoReward: UInt
) {
self.category = category
self.id = id
self.value = value
self.copoReward = copoReward
}

public init() {
self.init(
category: String(),
id: String(),
value: UInt()
value: UInt(),
copoReward: UInt()
)
}
}
Expand Down Expand Up @@ -797,7 +801,8 @@ public struct UserNotice: MessageWithBadges {
self.messageId = .viewerMilestone(.init(
category: parser.string(for: "msg-param-category"),
id: parser.string(for: "msg-param-id"),
value: parser.uint(for: "msg-param-value")
value: parser.uint(for: "msg-param-value"),
copoReward: parser.uint(for: "msg-param-copoReward")
))
occasionalSubDependentKeyGroups = []
default: return nil
Expand Down

0 comments on commit 33b2614

Please sign in to comment.