core syntax: strip the path from filename on syntax.get (#1168)
This commit is contained in:
parent
f02b3c46e6
commit
af6c4bc152
|
@ -44,7 +44,7 @@ local function find(string, field)
|
||||||
end
|
end
|
||||||
|
|
||||||
function syntax.get(filename, header)
|
function syntax.get(filename, header)
|
||||||
return find(filename, "files")
|
return find(common.basename(filename), "files")
|
||||||
or (header and find(header, "headers"))
|
or (header and find(header, "headers"))
|
||||||
or plain_text_syntax
|
or plain_text_syntax
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue