Bindings can be created from any SequenceType of DatabaseValue, not only CollectionType

This commit is contained in:
Gwendal Roué committed 2015-07-02 13:14:31 +02:00
1 parent 343a239905
commit 9ca4d2de46
1 file changed
+2 -2
+2 -2
View File
@@ -13,11 +13,11 @@ protocol BindingsImpl {
public struct Bindings {
let impl: BindingsImpl
public init<C: CollectionType where C.Generator.Element == Optional<DatabaseValue>>(_ array: C) {
public init<C: SequenceType where C.Generator.Element == Optional<DatabaseValue>>(_ array: C) {
impl = BindingsArrayImpl(array: array.map { $0 })
}
public init<C: CollectionType where C.Generator.Element == DatabaseValue>(_ array: C) {
public init<C: SequenceType where C.Generator.Element == DatabaseValue>(_ array: C) {
impl = BindingsArrayImpl(array: array.map { $0 })
}