mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-21 20:21:38 +00:00
Stylua formatting (#785)
Uses Stylua to format all existing Lua files, and adds a CI check in `lint` to pin this improvement. Excludes formatting dependencies, of course.
This commit is contained in:
parent
840e9bedb2
commit
0f8e1625d5
52 changed files with 595 additions and 549 deletions
|
|
@ -469,13 +469,17 @@ function App:startSession()
|
|||
if confirmationBehavior == "Initial" then
|
||||
-- Only confirm if we haven't synced this project yet this session
|
||||
if self.knownProjects[serverInfo.projectName] then
|
||||
Log.trace("Accepting patch without confirmation because project has already been connected and behavior is set to Initial")
|
||||
Log.trace(
|
||||
"Accepting patch without confirmation because project has already been connected and behavior is set to Initial"
|
||||
)
|
||||
return "Accept"
|
||||
end
|
||||
elseif confirmationBehavior == "Large Changes" then
|
||||
-- Only confirm if the patch impacts many instances
|
||||
if PatchSet.countInstances(patch) < Settings:get("largeChangesConfirmationThreshold") then
|
||||
Log.trace("Accepting patch without confirmation because patch is small and behavior is set to Large Changes")
|
||||
Log.trace(
|
||||
"Accepting patch without confirmation because patch is small and behavior is set to Large Changes"
|
||||
)
|
||||
return "Accept"
|
||||
end
|
||||
elseif confirmationBehavior == "Unlisted PlaceId" then
|
||||
|
|
@ -483,7 +487,9 @@ function App:startSession()
|
|||
if serverInfo.expectedPlaceIds then
|
||||
local isListed = table.find(serverInfo.expectedPlaceIds, game.PlaceId) ~= nil
|
||||
if isListed then
|
||||
Log.trace("Accepting patch without confirmation because placeId is listed and behavior is set to Unlisted PlaceId")
|
||||
Log.trace(
|
||||
"Accepting patch without confirmation because placeId is listed and behavior is set to Unlisted PlaceId"
|
||||
)
|
||||
return "Accept"
|
||||
end
|
||||
end
|
||||
|
|
@ -657,7 +663,8 @@ function App:render()
|
|||
}),
|
||||
|
||||
Settings = createPageElement(AppStatus.Settings, {
|
||||
syncActive = self.serveSession ~= nil and self.serveSession:getStatus() == ServeSession.Status.Connected,
|
||||
syncActive = self.serveSession ~= nil
|
||||
and self.serveSession:getStatus() == ServeSession.Status.Connected,
|
||||
|
||||
onBack = function()
|
||||
self:setState({
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue