nvimdev / dashboard-nvim

vim dashboard
MIT License
2.19k stars 177 forks source link

"attempt to perform arithmetic on a nil value" when passing shortcut = {} for theme hyper #436

Closed ilan-schemoul closed 3 months ago

ilan-schemoul commented 3 months ago

Describe the bug Error executing vim.schedule lua callback: .../code/forks/dashboard-nvim/lua/d ashboard/theme/hyper.lua:30: attempt to perform arithmetic on a nil value stack traceback: .../code/forks/dashboard-nvim/lua/dashboard/theme/hyper.lua:30: in fun ction 'gen_shortcut' .../code/forks/dashboard-nvim/lua/dashboard/theme/hyper.lua:502: in fu nction 'callback' .../code/forks/dashboard-nvim/lua/dashboard/theme/hyper.lua:155: in fu nction '' vim/_editor.lua: in function <vim/_editor.lua:0>

To Reproduce Steps to reproduce the behavior:

    require('dashboard').setup {
      theme = 'hyper',
      config = {
        header = {},
        shortcut = {},
      }
    }

Expected behavior No errors

ilan-schemoul commented 3 months ago

I made a pull request #437