fixed double negation in WaitForClient

This commit is contained in:
Milarin 2024-08-26 21:58:26 +02:00
parent f358112c7e
commit 2b5b3f84cb

View File

@ -82,7 +82,7 @@ func WaitForDefaultClient(ctx context.Context) (*Client, error) {
func WaitForClient(ctx context.Context, signature string) (*Client, error) { func WaitForClient(ctx context.Context, signature string) (*Client, error) {
lockFilePath := fmt.Sprintf("/run/user/1000/hypr/%s/hyprland.lock", signature) 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) _, err := os.Stat(lockFilePath)
return !errors.Is(err, os.ErrNotExist) return !errors.Is(err, os.ErrNotExist)
}) })