浏览代码

Fix error message;

bjorn 9 年之前
父节点
当前提交
626a7995f4
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      util.lua

+ 1 - 1
util.lua

@@ -66,7 +66,7 @@ function util.coerceValue(node, schemaType, variables)
 
 
   if schemaType.__type == 'Scalar' then
   if schemaType.__type == 'Scalar' then
     if schemaType.parseLiteral(node) == nil then
     if schemaType.parseLiteral(node) == nil then
-      error('Could not coerce "' .. node.value .. '" to "' .. schemaType.name .. '"')
+      error('Could not coerce "' .. tostring(node.value) .. '" to "' .. schemaType.name .. '"')
     end
     end
 
 
     return schemaType.parseLiteral(node)
     return schemaType.parseLiteral(node)