Handle nil blob names

This commit is contained in:
Vicent Marti
2014-06-16 18:41:51 +02:00
parent 463f48f04f
commit ea1fc90cf5
3 changed files with 3 additions and 3 deletions

View File

@@ -34,7 +34,7 @@ module Linguist
# Public: Read file permissions
#
# Returns a String like '0100644'
# Returns a String like '100644'
def mode
File.stat(@path).mode.to_s(8)
end

View File

@@ -94,7 +94,7 @@ module Linguist
#
# Returns Language or nil.
def self.detect(blob)
name = blob.name
name = blob.name.to_s
# A bit of an elegant hack. If the file is executable but extensionless,
# append a "magic" extension so it can be classified with other

View File

@@ -1,3 +1,3 @@
module Linguist
VERSION = "2.13.0.github3"
VERSION = "2.13.0.github4"
end