PHP 8.4 fixes.
This commit is contained in:
parent
325f5b5c86
commit
a074aceddd
11 changed files with 10 additions and 4 deletions
|
@ -1032,9 +1032,6 @@ if($reqPath === '/auth/register') {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!isset($authError)) {
|
if(!isset($authError)) {
|
||||||
if(!preg_match('#^([a-zA-Z0-9-_]{1,20})$#', $registerUsername)) {
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$createdUser = User::create(
|
$createdUser = User::create(
|
||||||
$registerUsername,
|
$registerUsername,
|
||||||
|
|
|
@ -9,6 +9,6 @@ class HtmlText implements HtmlTypeInterface {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function asHTML(): string {
|
public function asHTML(): string {
|
||||||
return htmlspecialchars($this->text);
|
return htmlspecialchars($this->text, ENT_COMPAT | ENT_SUBSTITUTE | ENT_HTML5);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@ use Exception;
|
||||||
class UploadNotFoundException extends Exception {};
|
class UploadNotFoundException extends Exception {};
|
||||||
class UploadCreationFailedException extends Exception {};
|
class UploadCreationFailedException extends Exception {};
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class Upload {
|
final class Upload {
|
||||||
private const ID_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_';
|
private const ID_CHARS = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_';
|
||||||
|
|
||||||
|
|
|
@ -9,6 +9,7 @@ class UserCreationInvalidNameException extends Exception {}
|
||||||
class UserCreationInvalidPasswordException extends Exception {}
|
class UserCreationInvalidPasswordException extends Exception {}
|
||||||
class UserCreationInvalidMailException extends Exception {}
|
class UserCreationInvalidMailException extends Exception {}
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
class User {
|
class User {
|
||||||
public function __construct() {
|
public function __construct() {
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,7 @@ use Exception;
|
||||||
class UserInviteNotFoundException extends Exception {}
|
class UserInviteNotFoundException extends Exception {}
|
||||||
class UserInviteCreationFailedException extends Exception {}
|
class UserInviteCreationFailedException extends Exception {}
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class UserInvite {
|
final class UserInvite {
|
||||||
private const TOKEN_LENGTH = 16;
|
private const TOKEN_LENGTH = 16;
|
||||||
|
|
||||||
|
|
|
@ -6,6 +6,7 @@ use Exception;
|
||||||
final class UserSessionNotFoundException extends Exception {};
|
final class UserSessionNotFoundException extends Exception {};
|
||||||
final class UserSessionCreatedFailedException extends Exception {};
|
final class UserSessionCreatedFailedException extends Exception {};
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
class UserSession {
|
class UserSession {
|
||||||
private const TOKEN_CHARS = 'abcdefghijklmnopqrstuvwxyz-0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZ';
|
private const TOKEN_CHARS = 'abcdefghijklmnopqrstuvwxyz-0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZ';
|
||||||
private static $instance = null;
|
private static $instance = null;
|
||||||
|
|
|
@ -9,6 +9,7 @@ class ZoneInvalidIdException extends Exception {};
|
||||||
class ZoneInvalidNameException extends Exception {};
|
class ZoneInvalidNameException extends Exception {};
|
||||||
class ZoneInvalidTitleException extends Exception {};
|
class ZoneInvalidTitleException extends Exception {};
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class Zone {
|
final class Zone {
|
||||||
private $effects = null;
|
private $effects = null;
|
||||||
private $passiveMode = false;
|
private $passiveMode = false;
|
||||||
|
|
|
@ -5,6 +5,7 @@ use Exception;
|
||||||
|
|
||||||
class ZoneEffectClassNotFoundException extends Exception {};
|
class ZoneEffectClassNotFoundException extends Exception {};
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class ZoneEffect {
|
final class ZoneEffect {
|
||||||
private const CLASS_NAME = '\\YTKNS\\Effects\\%sEffect';
|
private const CLASS_NAME = '\\YTKNS\\Effects\\%sEffect';
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace YTKNS;
|
namespace YTKNS;
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class ZoneRedirect {
|
final class ZoneRedirect {
|
||||||
public function __construct() {
|
public function __construct() {
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace YTKNS;
|
namespace YTKNS;
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class ZoneTask {
|
final class ZoneTask {
|
||||||
public function getZoneId(): int {
|
public function getZoneId(): int {
|
||||||
return $this->zone_id ?? 0;
|
return $this->zone_id ?? 0;
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
namespace YTKNS;
|
namespace YTKNS;
|
||||||
|
|
||||||
|
#[\AllowDynamicProperties]
|
||||||
final class ZoneView {
|
final class ZoneView {
|
||||||
private const THRESHOLD = 60 * 60 * 24;
|
private const THRESHOLD = 60 * 60 * 24;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue