aboutsummaryrefslogtreecommitdiffstats
path: root/util/serialization.lua
diff options
context:
space:
mode:
Diffstat (limited to 'util/serialization.lua')
-rw-r--r--util/serialization.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/serialization.lua b/util/serialization.lua
index 74d83a50..960794f2 100644
--- a/util/serialization.lua
+++ b/util/serialization.lua
@@ -151,9 +151,9 @@ local function new(opt)
elseif mt then
tag = mt.__type;
end
- if fr then
+ if type(fr) == "function" then
t = fr(t);
- if tag then
+ if type(tag) == "string" then
o[l], l = tag, l + 1;
end
end