aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorRunxi Yu <me@runxiyu.org>2024-12-08 09:18:56 +0800
committerRunxi Yu <me@runxiyu.org>2024-12-08 09:18:56 +0800
commit0cef5854b25d6300da9ac6b26b1ebefe7e235132 (patch)
tree5b57d6f943774963aeb53712720126c54da4dfeb /main.go
parentCAP: Stub (diff)
downloadmeseircd-0cef5854b25d6300da9ac6b26b1ebefe7e235132.tar.gz
meseircd-0cef5854b25d6300da9ac6b26b1ebefe7e235132.tar.zst
meseircd-0cef5854b25d6300da9ac6b26b1ebefe7e235132.zip
Remove unnecessary anonymous function
Diffstat (limited to '')
-rw-r--r--main.go4
1 files changed, 1 insertions, 3 deletions
diff --git a/main.go b/main.go
index 15a885c..42543f6 100644
--- a/main.go
+++ b/main.go
@@ -37,9 +37,7 @@ func main() {
slog.Error("connection routine panicked", "raised", raised)
}
}()
- defer func() {
- conn.Close()
- }()
+ defer conn.Close()
client, err := NewLocalClient(&conn)
if err != nil {
slog.Error("cannot make new local client", "error", err)