akinsho / akinsho/bufferline.nvim

[Bug]: vim.F.if_nil is deprecated. Feature will be removed in Nvim 0.15

Aperta
#1,054 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
Lua
Stelle
4.4k
Fork
240
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

### Is there an existing issue for this?

- [x] I have searched the existing issues

### What happened?

vim.F.if_nil is deprecated and will be removed in an upcoming version.

From what I understand, the change is as simple as replacing `vim.F.if_nil` by `vim.nonnil()`.

Here is the full error message:

```
- ⚠️ WARNING vim.F.if_nil is deprecated. Feature will be removed in Nvim 0.15
- ADVICE:
- use vim.nonnil instead.
- stack traceback:
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/highlights.lua:66
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/highlights.lua:79
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline.lua:200
/home/vandal/repos/nvim-local/opt/LazyVim/lua/lazyvim/plugins/ui.lua:52
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/loader.lua:380
=[C]:-1
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/util.lua:135
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/loader.lua:395
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/loader.lua:362
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/loader.lua:197
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/event.lua:85
=[C]:-1
/home/vandal/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/util.lua:175
- stack traceback:
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/highlights.lua:66
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/highlights.lua:116
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/ui.lua:238
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline/ui.lua:472
vim/_core/shared:286
/home/vandal/.local/share/nvim/lazy/bufferline.nvim/lua/bufferline.lua:56
=[C]:-1
/usr/share/nvim/runtime/lua/vim/health.lua:389
/usr/share/nvim/runtime/lua/vim/health.lua:465
```

### What did you expect to happen?

Expected behaviour: no deprecated notification.

### Config

The configuration is the one from LazyVim: https://www.lazyvim.org/plugins/ui#bufferlinenvim, but with `vim.g.deprecation_warnings = true` to see the warnings.

### Additional Information

_No response_

### commit

_No response_

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.