Skip to content

Commit 0268f82

Browse files
committed
Fix cd function breakage
1 parent 0bf2128 commit 0268f82

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

autoload/composer.vim

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ endfunction
134134
" Change working directory to project root or [dir], respecting current
135135
" window's local dir state. Returns old working directory to be restored later
136136
" by a second invocation of the function.
137-
function! s:project_cd(...) abort
137+
function! s:project_cd(...) dict abort
138138
let dir = get(a:000, 0, self.path())
139139
let cd = exists('*haslocaldir') && haslocaldir() ? 'lcd' : 'cd'
140140
let cwd = getcwd()
@@ -219,10 +219,10 @@ endfunction
219219
" Get output from Composer with {args} in project's root directory.
220220
function! s:project_exec(args) dict abort
221221
try
222-
let cwd = s:cd(self.path())
222+
let cwd = self.cd(self.path())
223223
let result = system(join([self.makeprg()] + a:args))
224224
finally
225-
call s:cd(cwd)
225+
call self.cd(cwd)
226226
endtry
227227

228228
return result

0 commit comments

Comments
 (0)