Skip to content

Commit

Permalink
refactor: remove redundant conditional
Browse files Browse the repository at this point in the history
Removes one of the nested conditionals:

```lua
if config.exclude then
    if config.exclude then
```
  • Loading branch information
wincent authored Nov 11, 2024
1 parent e51b651 commit 18e14fe
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions lua/ibl/config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -231,13 +231,12 @@ local validate_config = function(config)
end
end


if config.exclude then
if config.exclude then
utils.validate_config({
filetypes = { config.exclude.filetypes, "table", true },
buftypes = { config.exclude.buftypes, "table", true },
}, config.exclude, "ibl.config.exclude")
end
utils.validate_config({
filetypes = { config.exclude.filetypes, "table", true },
buftypes = { config.exclude.buftypes, "table", true },
}, config.exclude, "ibl.config.exclude")
end
end

Expand Down

0 comments on commit 18e14fe

Please sign in to comment.