summaryrefslogtreecommitdiff
path: root/server/src/service.lua
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/service.lua')
-rw-r--r--server/src/service.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/service.lua b/server/src/service.lua
index 9a5f5313..1d15fb0a 100644
--- a/server/src/service.lua
+++ b/server/src/service.lua
@@ -150,12 +150,12 @@ function mt:isOpen(uri)
end
end
-function mt:readText(uri, path)
+function mt:readText(uri, path, buf)
local obj = self._file[uri]
if obj then
return
end
- local text = io.load(path)
+ local text = buf or io.load(path)
if not text then
log.debug('无法找到文件:', path)
return