diff --git a/runtime/optwin.vim b/runtime/optwin.vim index 47e165f455..26c80e5ce0 100644 --- a/runtime/optwin.vim +++ b/runtime/optwin.vim @@ -1,11 +1,11 @@ " These commands create the option window. " " Maintainer: The Vim Project -" Last Change: 2025 Jul 25 +" Last Change: 2025 Aug 07 " Former Maintainer: Bram Moolenaar " If there already is an option window, jump to that one. -let buf = bufnr('option-window') +let buf = bufexists('option-window') ? bufnr('option-window') : -1 if buf >= 0 let winids = win_findbuf(buf) if len(winids) > 0