Remove ancient guard against legacy 'commit' parameter

People often copy and paste this plugin as a starting point for their
own, so let's clean this up.
This commit is contained in:
Tim Pope
2021-08-17 23:11:05 -04:00
parent 6aaa229db8
commit e804fb67b7

View File

@@ -265,11 +265,7 @@ function! rhubarb#FugitiveUrl(...) abort
elseif path =~# '^\.git\>'
return root
endif
if opts.commit =~# '^\d\=$'
return ''
else
let commit = opts.commit
endif
if get(opts, 'type', '') ==# 'tree' || opts.path =~# '/$'
let url = substitute(root . '/tree/' . commit . '/' . path, '/$', '', 'g')
elseif get(opts, 'type', '') ==# 'blob' || opts.path =~# '[^/]$'