mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Fix 1.9 string grep
This commit is contained in:
@@ -470,7 +470,7 @@ module Linguist
|
||||
Language['Objective-C']
|
||||
|
||||
# Matlab file function or class or comments
|
||||
elsif lines.any? && lines.first.grep(/^\s*(function |classdef )/).any? || lines.grep(/^\s*%/).any?
|
||||
elsif lines.any? && lines.first.match(/^\s*(function |classdef )/) || lines.grep(/^\s*%/).any?
|
||||
Language['Matlab']
|
||||
|
||||
# Fallback to Objective-C, don't want any Matlab false positives
|
||||
|
||||
Reference in New Issue
Block a user