diff options
Diffstat (limited to 'server-beta/src')
-rw-r--r-- | server-beta/src/proto/define.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/server-beta/src/proto/define.lua b/server-beta/src/proto/define.lua index 62c85989..9a890e2e 100644 --- a/server-beta/src/proto/define.lua +++ b/server-beta/src/proto/define.lua @@ -47,7 +47,9 @@ function m.range(lines, text, offset1, offset2) start = m.position(lines, text, offset1), ['end'] = m.position(lines, text, offset2), } - range.start.character = range.start.character - 1 + if range.start.character > 0 then + range.start.character = range.start.character - 1 + end return range end |