Skip to content

Commit

Permalink
🐛 Fix infinite loop in ftp adapter (php 8.1) (#663)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nek- authored Sep 24, 2022
1 parent bab98cb commit 79b030a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Gaufrette/Adapter/Ftp.php
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,10 @@ private function computePath($key)
*/
private function isConnected()
{
if (class_exists('\FTP\Connection')) {
return $this->connection instanceof \FTP\Connection;
}

return is_resource($this->connection);
}

Expand Down

0 comments on commit 79b030a

Please sign in to comment.