Class: RuboCop::Cop::Homebrew::SafeNavigationWithBlank Private
- Extended by:
- AutoCorrector
- Defined in:
- rubocops/safe_navigation_with_blank.rb,
sorbet/rbi/dsl/rubo_cop/cop/homebrew/safe_navigation_with_blank.rbi
Overview
This class is part of a private API. This class may only be used in the Homebrew/brew repository. Third parties should avoid using this class if possible, as it may be removed or changed without warning.
DO NOT EDIT MANUALLY
This is an autogenerated file for dynamic methods in RuboCop::Cop::Homebrew::SafeNavigationWithBlank
.
Please instead update this file by running bin/tapioca dsl RuboCop::Cop::Homebrew::SafeNavigationWithBlank
.
Constant Summary collapse
- MSG =
This constant is part of a private API. This constant may only be used in the Homebrew/brew repository. Third parties should avoid using this constant if possible, as it may be removed or changed without warning.
"Avoid calling `blank?` with the safe navigation operator in conditionals."
Instance Method Summary collapse
- #on_if(node) ⇒ Object private
- #safe_navigation_blank_in_conditional?(node, **kwargs, &block) ⇒ T.untyped private
Instance Method Details
#on_if(node) ⇒ Object
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
39 40 41 42 43 44 45 |
# File 'rubocops/safe_navigation_with_blank.rb', line 39 def on_if(node) return unless (node) add_offense(node) do |corrector| corrector.replace((node).location.dot, ".") end end |
#safe_navigation_blank_in_conditional?(node, **kwargs, &block) ⇒ T.untyped
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
9 |
# File 'sorbet/rbi/dsl/rubo_cop/cop/homebrew/safe_navigation_with_blank.rbi', line 9 def (node, **kwargs, &block); end |