Skip to content

Commit

Permalink
perf: replace vim.g with _G in init check
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcjkb committed May 16, 2024
1 parent 69ab794 commit 509e872
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugin/rocks.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
-- Homepage: https://github.com/nvim-neorocks/rocks.nvim
-- Maintainers: NTBBloodbath <bloodbathalchemist@protonmail.com>, Vhyrro <vhyrro@gmail.com>, mrcjkb <marc@jakobi.dev>

if vim.g.rocks_nvim_loaded then
if _G.rocks_nvim_loaded then
return
end

Expand Down Expand Up @@ -58,4 +58,4 @@ local user_rocks = config.get_user_rocks()
require("rocks.api.hooks").run_preload_hooks(user_rocks)
require("rocks.runtime").source_start_plugins(user_rocks)

vim.g.rocks_nvim_loaded = true
_G.rocks_nvim_loaded = true

0 comments on commit 509e872

Please sign in to comment.