diff --git a/src/scripting/scriptengine.cpp b/src/scripting/scriptengine.cpp index 6c740cb7f0..83098a1900 100644 --- a/src/scripting/scriptengine.cpp +++ b/src/scripting/scriptengine.cpp @@ -115,7 +115,7 @@ namespace { json << fmt::format(replStr, "returnType", escapedJson(f.returnType)); json << fmt::format(replStr, "help", escapedJson(f.helpText)); json << fmt::format( - "\"sourceLocation\": {{ \"file\": {}, \"line\": {} }}", + "\"sourceLocation\": {{ \"file\": \"{}\", \"line\": {} }}", escapedJson(f.sourceLocation.file), f.sourceLocation.line ); json << "}";