mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Add max selections support for polls (#5726)
This commit is contained in:
committed by
GitHub
parent
173a927bf8
commit
30e4e6339d
@@ -11,13 +11,14 @@ import Foundation
|
||||
extension Poll {
|
||||
static func mock(question: String,
|
||||
pollKind: Poll.Kind = .disclosed,
|
||||
maxSelections: Int = 1,
|
||||
options: [Poll.Option],
|
||||
votes: [String: [String]] = [:],
|
||||
ended: Bool = false,
|
||||
createdByAccountOwner: Bool = false) -> Self {
|
||||
.init(question: question,
|
||||
kind: pollKind,
|
||||
maxSelections: 1,
|
||||
maxSelections: maxSelections,
|
||||
options: options,
|
||||
votes: votes,
|
||||
endDate: ended ? Date() : nil,
|
||||
|
||||
Reference in New Issue
Block a user