Skip to content

Commit 7092583

Browse files
committed
Fix "Non-canonical cast (double) is deprecated" in PHP 8.5
1 parent 37edc9a commit 7092583

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

ChangeLog.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@ FTP protocol support for the XP Framework ChangeLog
33

44
## ?.?.? / ????-??-??
55

6+
* Fixed deprecation warning *Non-canonical cast (double) is deprecated,
7+
use the (float) cast instead* in PHP 8.5
8+
(@thekid)
9+
610
## 11.1.0 / 2024-03-24
711

812
* Made compatible with XP 12 - @thekid
9-
1013
* Added PHP 8.2, 8.3 and 8.4 to the test matrix - @thekid
1114

1215
## 11.0.3 / 2021-10-21

src/main/php/peer/ftp/FtpConnection.class.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ public function remoteEndpoint() { return $this->socket->remoteEndpoint(); }
8989
/** @return bool */
9090
public function passive() { return $this->passive; }
9191

92-
/** @return double */
93-
public function timeout() { return (double)$this->url->getParam('timeout', 4); }
92+
/** @return float */
93+
public function timeout() { return (float)$this->url->getParam('timeout', 4.0); }
9494

9595
/**
9696
* Connect (and log in, if necessary)

0 commit comments

Comments
 (0)