instance method
DidYouMean::TreeSpellChecker#correct
(::String input) -> ::Array[::String]
correct(input)
lib/did_you_mean/tree_spell_checker.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.0.0/lib/did_you_mean/tree_spell_checker.rb, line 15
def correct(input)
plausibles = plausible_dimensions(input)
return fall_back_to_normal_spell_check(input) if plausibles.empty?
suggestions = find_suggestions(input, plausibles)
return fall_back_to_normal_spell_check(input) if suggestions.empty?
suggestions
end
No documentation available