We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6b7151 commit 9ba4731Copy full SHA for 9ba4731
1 file changed
src/flex-lua-geom.cpp
@@ -309,11 +309,11 @@ void init_geometry_class(lua_State *lua_state)
309
// Add metatable as osm2pgsql.Geometry so we can access it from Lua
310
lua_setfield(lua_state, -3, "Geometry");
311
312
+ lua_pushvalue(lua_state, -1);
313
+ lua_setfield(lua_state, -2, "__index");
314
luaX_add_table_func(lua_state, "__gc", geom_gc);
315
luaX_add_table_func(lua_state, "__len", geom_num_geometries);
316
luaX_add_table_func(lua_state, "__tostring", geom_tostring);
- lua_pushvalue(lua_state, -1);
- lua_setfield(lua_state, -2, "__index");
317
luaX_add_table_func(lua_state, "area", geom_area);
318
luaX_add_table_func(lua_state, "length", geom_length);
319
luaX_add_table_func(lua_state, "centroid", geom_centroid);
0 commit comments