fix stack overflow error on RawRepresentable encoding
This commit is contained in:
parent
58afcc596d
commit
1eb0103744
@ -32,9 +32,4 @@ extension RawRepresentableCodable {
|
|||||||
throw RawRepresentableCodableError.invalid(value: "\(rawValue)")
|
throw RawRepresentableCodableError.invalid(value: "\(rawValue)")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public func encode(to encoder: Encoder) throws {
|
|
||||||
var container = encoder.singleValueContainer()
|
|
||||||
try container.encode(self)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user