summaryrefslogtreecommitdiff
path: root/src/lua
diff options
context:
space:
mode:
Diffstat (limited to 'src/lua')
-rw-r--r--src/lua/include/property.hpp2
-rw-r--r--src/lua/property.cpp2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/lua/include/property.hpp b/src/lua/include/property.hpp
index 207696bd..c1dcf44b 100644
--- a/src/lua/include/property.hpp
+++ b/src/lua/include/property.hpp
@@ -26,6 +26,8 @@ class Property {
Property(const LuaValue&);
Property(const LuaValue&, std::function<bool(const LuaValue&)>);
+ auto Get() -> const LuaValue& { return value_; }
+
auto IsTwoWay() -> bool { return cb_.has_value(); }
auto PushValue(lua_State& s) -> int;
diff --git a/src/lua/property.cpp b/src/lua/property.cpp
index 3e492237..b424a866 100644
--- a/src/lua/property.cpp
+++ b/src/lua/property.cpp
@@ -221,7 +221,7 @@ auto Property::PopValue(lua_State& s) -> bool {
}
break;
case LUA_TBOOLEAN:
- new_val = lua_toboolean(&s, 2);
+ new_val = static_cast<bool>(lua_toboolean(&s, 2));
break;
case LUA_TSTRING:
new_val = lua_tostring(&s, 2);