fix PHP8 errors
Dieser Commit ist enthalten in:
Ursprung
b199edaf8e
Commit
4aba95edd1
|
@ -122,7 +122,7 @@ function canWriteFile($sFilename) {
|
||||||
* a wrong information
|
* a wrong information
|
||||||
*/
|
*/
|
||||||
$fp = @fopen($sRandFilenamePath, "w");
|
$fp = @fopen($sRandFilenamePath, "w");
|
||||||
if ($fp) {
|
if (is_resource($fp)) {
|
||||||
@fclose($fp);
|
@fclose($fp);
|
||||||
unlink($sRandFilenamePath);
|
unlink($sRandFilenamePath);
|
||||||
return true;
|
return true;
|
||||||
|
@ -143,8 +143,10 @@ function canWriteFile($sFilename) {
|
||||||
/* Ignore errors in case isWriteable() returns
|
/* Ignore errors in case isWriteable() returns
|
||||||
* a wrong information
|
* a wrong information
|
||||||
*/
|
*/
|
||||||
$fp = @fopen($sFilename, "w");
|
$fp = fopen($sFilename, "w");
|
||||||
@fclose($fp);
|
if (is_resource($fp)) {
|
||||||
|
fclose($fp);
|
||||||
|
}
|
||||||
|
|
||||||
if (file_exists($sFilename)) {
|
if (file_exists($sFilename)) {
|
||||||
@unlink($sFilename);
|
@unlink($sFilename);
|
||||||
|
|
Laden…
In neuem Issue referenzieren