aboutsummaryrefslogtreecommitdiff
path: root/src/universe.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/universe.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/universe.cpp b/src/universe.cpp
index 4dd956d..095f000 100644
--- a/src/universe.cpp
+++ b/src/universe.cpp
@@ -67,7 +67,7 @@ Universe* universe_get(lua_State* L)
67 STACK_GROW(L, 2); 67 STACK_GROW(L, 2);
68 STACK_CHECK_START_REL(L, 0); 68 STACK_CHECK_START_REL(L, 0);
69 UNIVERSE_REGKEY.query_registry(L); 69 UNIVERSE_REGKEY.query_registry(L);
70 Universe* const universe = static_cast<Universe*>(lua_touserdata(L, -1)); // nullptr if nil 70 Universe* const universe{ lua_touserdata<Universe>(L, -1) }; // nullptr if nil
71 lua_pop(L, 1); 71 lua_pop(L, 1);
72 STACK_CHECK(L, 0); 72 STACK_CHECK(L, 0);
73 return universe; 73 return universe;