Skip to content

Commit

Permalink
Fix ai.aspects.avoid always returning an empty table
Browse files Browse the repository at this point in the history
  • Loading branch information
CelticMinstrel committed Nov 27, 2019
1 parent cfd23bd commit 5b7383c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ai/lua/lua_object.hpp
Expand Up @@ -217,7 +217,7 @@ inline void lua_object<terrain_filter>::from_type(lua_State *L, std::shared_ptr<
lua_createtable(L, locs.size(), 0);
for(const map_location& loc : locs) {
luaW_pushlocation(L, loc);
lua_rawseti(L, -1, lua_rawlen(L, -2) + 1);
lua_rawseti(L, -2, lua_rawlen(L, -2) + 1);
}
} else lua_pushnil(L);
}
Expand Down

0 comments on commit 5b7383c

Please sign in to comment.