#49, #123 - Setup UI integration and performance testing (#148)

This commit is contained in:
Stefan Ceriu
2022-08-18 16:32:29 +03:00
committed by GitHub
parent b6e1d6d1e5
commit 78df4abc7f
27 changed files with 954 additions and 78 deletions
@@ -27,12 +27,10 @@ extension AuthenticationError {
var code: MatrixErrorCode {
guard case let .Generic(message) = self else { return .unknown }
for code in MatrixErrorCode.allCases {
if message.contains(code.rawValue) {
return code
}
guard let first = MatrixErrorCode.allCases.first(where: { message.contains($0.rawValue) }) else {
return .unknown
}
return .unknown
return first
}
}