Require primary extension to be set

This commit is contained in:
Joshua Peek
2011-08-01 10:24:21 -05:00
parent 903bb31f2b
commit ac89ff7f01
3 changed files with 14 additions and 1 deletions

View File

@@ -295,11 +295,17 @@ module Linguist
# Returns the extensions Array
attr_reader :extensions
# Public: Get primary extension
# Deprecated: Get primary extension
#
# Defaults to the first extension but can be overriden
# in the languages.yml.
#
# The primary extension can not be nil. Tests should verify this.
#
# This attribute is only used by app/helpers/gists_helper.rb for
# creating the language dropdown. It really should be using `name`
# instead. Would like to drop primary extension.
#
# Returns the extension String.
attr_reader :primary_extension