From 2b5b3f84cb367d2874609a07b5bf76bf1e007f1f Mon Sep 17 00:00:00 2001 From: Milarin Date: Mon, 26 Aug 2024 21:58:26 +0200 Subject: [PATCH] fixed double negation in WaitForClient --- get_clients.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/get_clients.go b/get_clients.go index 4c42986..01a8717 100644 --- a/get_clients.go +++ b/get_clients.go @@ -82,7 +82,7 @@ func WaitForDefaultClient(ctx context.Context) (*Client, error) { func WaitForClient(ctx context.Context, signature string) (*Client, error) { lockFilePath := fmt.Sprintf("/run/user/1000/hypr/%s/hyprland.lock", signature) - lockFileExists := !waitFor(ctx, func() bool { + lockFileExists := waitFor(ctx, func() bool { _, err := os.Stat(lockFilePath) return !errors.Is(err, os.ErrNotExist) })