Skip to content
This repository was archived by the owner on Feb 17, 2025. It is now read-only.

Commit 953713f

Browse files
authored
Merge pull request #64 from reactphp-parallel/no-need-to-call-close-from-destruct-when-we're-already-closed
No need to call closed from destruct when the proxy is already closed
2 parents db0a701 + 501a602 commit 953713f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Proxy.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,10 @@ public function close(): void
174174

175175
public function __destruct()
176176
{
177+
if ($this->closed === TRUE_) {
178+
return;
179+
}
180+
177181
$this->close();
178182
}
179183
}

0 commit comments

Comments
 (0)