From 6b2dbe282f92928e38d85788f0a6eee26c647042 Mon Sep 17 00:00:00 2001 From: CppCXY <812125110@qq.com> Date: Fri, 21 Jan 2022 19:27:41 +0800 Subject: =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script/core/formatting.lua | 4 ++-- script/core/rangeformatting.lua | 4 ++-- script/provider/provider.lua | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/script/core/formatting.lua b/script/core/formatting.lua index 8f72028b..6c57b8c2 100644 --- a/script/core/formatting.lua +++ b/script/core/formatting.lua @@ -1,11 +1,11 @@ -local code_format = require "code_format" +local codeFormat = require("code_format") local files = require("files") local log = require("log") return function(uri) local text = files.getText(uri) local ast = files.getState(uri) - local status, formattedText = code_format.format(uri, text) + local status, formattedText = codeFormat.format(uri, text) if not status then if formattedText ~= nil then diff --git a/script/core/rangeformatting.lua b/script/core/rangeformatting.lua index b66f0fbd..de9516c1 100644 --- a/script/core/rangeformatting.lua +++ b/script/core/rangeformatting.lua @@ -1,11 +1,11 @@ -local code_format = require "code_format" +local codeFormat = require("code_format") local files = require("files") local log = require("log") local converter = require("proto.converter") return function(uri, range) local text = files.getText(uri) - local status, formattedText, startLine, endLine = code_format.range_format( + local status, formattedText, startLine, endLine = codeFormat.range_format( uri, text, range.start.line, range["end"].line) if not status then diff --git a/script/provider/provider.lua b/script/provider/provider.lua index a5e0a1ca..9ca66b43 100644 --- a/script/provider/provider.lua +++ b/script/provider/provider.lua @@ -988,8 +988,8 @@ m.register 'config/editorconfig/update' { abortByFileUpdate = true, ---@async function(params) - local code_format = require "code_format" - local status, err = code_format.update_config(params.type, params.source.workspace, params.source.path) + local codeFormat = require "code_format" + local status, err = codeFormat.update_config(params.type, params.source.workspace, params.source.path) if not status and err ~= nil then log.error(err) -- cgit v1.2.3