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

attempt to index local (a userdata value) #1

Open
ghost opened this issue Dec 31, 2019 · 1 comment
Open

attempt to index local (a userdata value) #1

ghost opened this issue Dec 31, 2019 · 1 comment

Comments

@ghost
Copy link

ghost commented Dec 31, 2019

Here is my code:

local ip2location = require('resty.ip2location')
local ip2loc = ip2location.new("/usr/share/IPV6-COUNTRY.BIN", ip2location.IP2LOCATION_SHARED_MEMORY)

It shows me error:

attempt to index local 'ip2location' (a userdata value)
How can I fix it?

@ghost
Copy link
Author

ghost commented Jan 1, 2020

Problem was I should have installed ip2location C library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants