Add setters to MediaSticker
@@ -833,6 +833,17 @@ pub struct MediaPoll {
pub poll: Poll,
}
+impl MediaPoll {
+ pub fn new(poll: Poll) -> Self {
+ Self { poll }
+ }
+
+ pub fn poll(mut self, val: Poll) -> Self {
+ self.poll = val;
+ self
+ }
+}
+
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
#[non_exhaustive]
pub struct MediaSticker {
@@ -840,6 +851,17 @@ pub struct MediaSticker {
pub sticker: Sticker,
}
+impl MediaSticker {
+ pub fn new(sticker: Sticker) -> Self {
+ Self { sticker }
+ }
+
+ pub fn poll(mut self, val: Sticker) -> Self {
+ self.sticker = val;
+ self
+ }
+}
+
#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
#[non_exhaustive]
pub struct MediaText {
