Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

injecting db twice result in error #122

Open
kkharji opened this issue Sep 25, 2021 · 0 comments
Open

injecting db twice result in error #122

kkharji opened this issue Sep 25, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@kkharji
Copy link
Owner

kkharji commented Sep 25, 2021

According on AckslD/nvim-neoclip.lua#20 (comment)

local db = sqlite.new(db_path)
db:open()
local tbl = sqlite.tbl("neoclip", {
    id = true,
    regtype = "text",
    contents = "luatable",
    filetype = "text",
}, db)
tbl:set_db(db)

results in

.../sqlite/helpers.lua:71: bad argument #1 to 'next' (table expected, got function)

This shouldn't error and users should be able to switch db at anytime.

@kkharji kkharji added the bug Something isn't working label Sep 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant