Skip to content

Commit a111da6

Browse files
authored
Merge pull request #1470 from NeogitOrg/fix-style
2 parents f2b9f0e + d104c75 commit a111da6

File tree

2 files changed

+14
-19
lines changed

2 files changed

+14
-19
lines changed

lua/neogit/config.lua

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -634,22 +634,19 @@ function M.validate_config()
634634
local function validate_kind(val, name)
635635
if
636636
validate_type(val, name, "string")
637-
and not vim.tbl_contains(
638-
{
639-
"split",
640-
"vsplit",
641-
"split_above",
642-
"split_above_all",
643-
"split_below",
644-
"split_below_all",
645-
"vsplit_left",
646-
"tab",
647-
"floating",
648-
"replace",
649-
"auto",
650-
},
651-
val
652-
)
637+
and not vim.tbl_contains({
638+
"split",
639+
"vsplit",
640+
"split_above",
641+
"split_above_all",
642+
"split_below",
643+
"split_below_all",
644+
"vsplit_left",
645+
"tab",
646+
"floating",
647+
"replace",
648+
"auto",
649+
}, val)
653650
then
654651
err(
655652
name,

lua/neogit/lib/buffer.lua

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -277,14 +277,12 @@ function Buffer:show()
277277
elseif kind == "tab" then
278278
vim.cmd("tab sb " .. self.handle)
279279
win = api.nvim_get_current_win()
280-
elseif kind == "split" then
280+
elseif kind == "split" or kind == "split_below" then
281281
win = api.nvim_open_win(self.handle, true, { split = "below" })
282282
elseif kind == "split_above" then
283283
win = api.nvim_open_win(self.handle, true, { split = "above" })
284284
elseif kind == "split_above_all" then
285285
win = api.nvim_open_win(self.handle, true, { split = "above", win = -1 })
286-
elseif kind == "split_below" then
287-
win = api.nvim_open_win(self.handle, true, { split = "below" })
288286
elseif kind == "split_below_all" then
289287
win = api.nvim_open_win(self.handle, true, { split = "below", win = -1 })
290288
elseif kind == "vsplit" then

0 commit comments

Comments
 (0)