You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
editor.rb:9: Method upcase does not exist on NilClass component of T.nilable(String) https://srb.help/7003
9 | x&.downcase&.end_with?(x.upcase)
^^^^^^^^
Autocorrect: Use `-a` to autocorrect
editor.rb:9: Replace with T.must(x)
9 | x&.downcase&.end_with?(x.upcase)
^
Errors: 1
Expected behavior
As x.upcase is only evaluated when x is non-nil, sorbet should not complain about the NilClass component of x at this point
(Discovered while applying Style/SafeNavigation autocorrection)
The text was updated successfully, but these errors were encountered:
Input
→ View on sorbet.run
Observed output
Expected behavior
As
x.upcase
is only evaluated whenx
is non-nil, sorbet should not complain about theNilClass
component ofx
at this point(Discovered while applying
Style/SafeNavigation
autocorrection)The text was updated successfully, but these errors were encountered: