Skip to content

Commit f38a614

Browse files
committed
Fix formatting again
1 parent bceb95d commit f38a614

File tree

6 files changed

+36
-31
lines changed

6 files changed

+36
-31
lines changed

.github/workflows/dart.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ jobs:
6060
- name: Run build_runner
6161
if: matrix.projects == 'api' || matrix.projects == 'app'
6262
run: dart run build_runner build --delete-conflicting-outputs
63+
- name: Run format for generated files
64+
if: matrix.projects == 'api' || matrix.projects == 'app'
65+
run: dart format .
6366
- name: Test for git changes
6467
run: git diff --exit-code
6568
# Your project will need to have tests in test/ and a dependency on

app/lib/services/network.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ class NetworkService {
155155
),
156156
ListGameServer() => cached[server] = fetchInfo(
157157
server.buildAddress(webSockets: false),
158-
).onError((_, __) => null),
158+
).onError((_, _) => null),
159159
};
160160
}
161161

plugin/example/lua.dart

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,12 @@ Future<void> main() async {
1919
print("SANDBOX: ${p0}");
2020
},
2121
);
22-
callback.changeStateFieldAccess(stateFieldAccess: (p0) {
23-
print("FIELD: ${p0}");
24-
return '{"key": "value"}';
25-
});
22+
callback.changeStateFieldAccess(
23+
stateFieldAccess: (p0) {
24+
print("FIELD: ${p0}");
25+
return '{"key": "value"}';
26+
},
27+
);
2628
final plugin = LuauPlugin(code: LUA_SCRIPT, callback: callback);
2729
try {
2830
await plugin.run();

server/example/dialog.dart

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -47,18 +47,20 @@ Future<void> onLoad(SetonixServer server) async {
4747
server.defaultEventSystem
4848
..on<ObjectsMoved>((e) {
4949
print("Listener was called, opening dialog");
50-
server.sendEvent(DialogOpened(
51-
GameDialog(id: "testDialog", title: "TestDialog", image: "logo")
52-
.markdown(testContent)
53-
.textField(
54-
"TestTextField",
55-
id: "testTextField",
56-
placeholder: "TestPlaceholder",
57-
multiline: true,
58-
password: true,
59-
)
60-
.action(GameDialogButton("TestButton")),
61-
));
50+
server.sendEvent(
51+
DialogOpened(
52+
GameDialog(id: "testDialog", title: "TestDialog", image: "logo")
53+
.markdown(testContent)
54+
.textField(
55+
"TestTextField",
56+
id: "testTextField",
57+
placeholder: "TestPlaceholder",
58+
multiline: true,
59+
password: true,
60+
)
61+
.action(GameDialogButton("TestButton")),
62+
),
63+
);
6264
})
6365
..on<UserJoined>((e) {
6466
print("play joined");

server/example/duplicate.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ Future<void> onLoad(SetonixServer server) async {
2222
objects.add(object);
2323
}
2424
// Send the event to all clients
25-
server
26-
.sendEvent(ObjectsSpawned(e.clientEvent.table, {event.to: objects}));
25+
server.sendEvent(
26+
ObjectsSpawned(e.clientEvent.table, {event.to: objects}),
27+
);
2728
// Cancel the event
2829
e.cancel();
2930
}

server/example/join.dart

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,15 @@ Future<void> onLoad(SetonixServer server) async {
88
print("on load was called");
99
server.defaultEventSystem
1010
..on<UserJoined>((e) {
11-
server.sendEvent(DialogOpened(GameDialog(
12-
id: "joinDialog",
13-
title: "Please login",
14-
)
15-
.textField("Username", id: "username")
16-
.textField(
17-
"Password",
18-
id: "password",
19-
password: true,
20-
)
21-
.action(GameDialogButton("Login", id: "login"))
22-
.action(GameDialogButton("Register", id: "register"))));
11+
server.sendEvent(
12+
DialogOpened(
13+
GameDialog(id: "joinDialog", title: "Please login")
14+
.textField("Username", id: "username")
15+
.textField("Password", id: "password", password: true)
16+
.action(GameDialogButton("Login", id: "login"))
17+
.action(GameDialogButton("Register", id: "register")),
18+
),
19+
);
2320
})
2421
..on<DialogCloseRequest>((e) {
2522
final event = e.clientEvent;

0 commit comments

Comments
 (0)