File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -311,21 +311,22 @@ end
311311-- Construct the statusline (default)
312312function _G .statusline ()
313313 local winid = vim .g .statusline_winid or vim .api .nvim_get_current_win ()
314- local bufnr = statusline_bufnr (winid )
314+ local editing_bufnr = statusline_bufnr (winid )
315+ local actual_bufnr = vim .api .nvim_win_get_buf (winid )
315316 local hl = " %#StatusLine#"
316317
317318 local components = {
318319 hl ,
319320 c_mode (),
320321 c_spinner (),
321322 c_project (),
322- c_filename (bufnr ),
323+ c_filename (actual_bufnr ),
323324 c_bookmark (),
324325 " %=" ,
325326 " %=" ,
326- c_lsp_diagnostics (bufnr ),
327- c_git_status (bufnr ),
328- c_git_branch (bufnr ),
327+ c_lsp_diagnostics (editing_bufnr ),
328+ c_git_status (editing_bufnr ),
329+ c_git_branch (editing_bufnr ),
329330 c_cursor_position (),
330331 c_tabs (),
331332 }
You can’t perform that action at this time.
0 commit comments