We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
So I have this slightly redacted piece of code:
self.webSocketHandler.isConnected.filter { $0 }.first().observeNext { _ in }
It's giving me the following warning (not sure if it's SwiftLint or vanilla Xcode though...):
First Where Violation: Prefer using .first(where:)over.filter { }.first in collections. (first_where)
First Where Violation: Prefer using
over
in collections. (first_where)
However the first(where:) method doesn't seem to exist in that context.
first(where:)
It's not a big issue and perhaps I'm overlooking a better way to do it but it would be nice if it would actually have first(where:)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
So I have this slightly redacted piece of code:
self.webSocketHandler.isConnected.filter { $0 }.first().observeNext { _ in }
It's giving me the following warning (not sure if it's SwiftLint or vanilla Xcode though...):
First Where Violation: Prefer using
.first(where:)over
.filter { }.firstin collections. (first_where)
However the
first(where:)
method doesn't seem to exist in that context.It's not a big issue and perhaps I'm overlooking a better way to do it but it would be nice if it would actually have
first(where:)
The text was updated successfully, but these errors were encountered: