Fix dump() indentation with non-tab indents
authorShadowNinja <shadowninja@minetest.net>
Sat, 8 Nov 2014 17:48:05 +0000 (12:48 -0500)
committerShadowNinja <shadowninja@minetest.net>
Sat, 8 Nov 2014 17:49:50 +0000 (12:49 -0500)
builtin/common/misc_helpers.lua

index ce58b3f9bfac6a5fe8e3be1fba5d89f3374aa83c..a12de597007e3a3f71b4f6089724d9e36b47427f 100644 (file)
@@ -145,7 +145,7 @@ function dump(o, indent, nested, level)
        nested[o] = nil
        if indent ~= "" then
                local indent_str = "\n"..string.rep(indent, level)
-               local end_indent_str = "\n"..string.rep("\t", level - 1)
+               local end_indent_str = "\n"..string.rep(indent, level - 1)
                return string.format("{%s%s%s}",
                                indent_str,
                                table.concat(t, ","..indent_str),