Skip to content

Commit c2ec64e

Browse files
committed
Fix last method detection
1 parent 40827bb commit c2ec64e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

autoload/rails.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ function! s:readable_last_method(start) dict abort
257257
let string = matchstr(line,'^\s*\w\+\s*\([''"]\)\zs.*\ze\1')
258258
return 'test_'.s:gsub(string,' +','_')
259259
elseif lnum
260-
return s:sub(matchstr(lnum,'\%('.self.define_pattern().'\)\zs\h\%(\k\|[:.]\)*[?!=]\='),':$','')
260+
return s:sub(matchstr(line,'\%('.self.define_pattern().'\)\zs\h\%(\k\|[:.]\)*[?!=]\='),':$','')
261261
else
262262
return ""
263263
endif

0 commit comments

Comments
 (0)