From 577fb95384e154d698971884bcfd8a50d7983102 Mon Sep 17 00:00:00 2001 From: Brandon Keepers Date: Fri, 28 Nov 2014 17:36:14 -0600 Subject: [PATCH] Tweak docs --- lib/linguist/language.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/linguist/language.rb b/lib/linguist/language.rb index 07972019..2353edd1 100644 --- a/lib/linguist/language.rb +++ b/lib/linguist/language.rb @@ -110,16 +110,16 @@ module Linguist # Bail early if the blob is binary or empty. return nil if blob.likely_binary? || blob.binary? || blob.empty? - # Call each strategy until one candidate is returned + # Call each strategy until one candidate is returned. STRATEGIES.reduce([]) do |languages, strategy| candidates = strategy.call(blob, languages) if candidates.size == 1 return candidates.first elsif candidates.size > 1 - # More than one candidate was found, pass them to the next strategy + # More than one candidate was found, pass them to the next strategy. candidates else - # Strategy couldn't find any candidates, so pass on the original list + # No candiates were found, pass on languages from the previous strategy. languages end end.first