summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2023-01-29 13:49:13 +0100
committerFlorian Pritz <bluewind@xinu.at>2023-01-29 13:49:56 +0100
commit457e351cbc1335de951f4ac79bb91a9f3ea9ab38 (patch)
treeae4761695073dce3be7875bd23824af0b1d2b84c
parent1aa385f82a583f0982b7c14d8629f491d0b78f88 (diff)
feat(PHP8.2): Fix dynamic properties deprecation warnings
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rw-r--r--NEWS1
-rw-r--r--system/core/Controller.php1
-rw-r--r--system/core/Loader.php1
-rw-r--r--system/core/Router.php3
-rw-r--r--system/core/URI.php2
-rw-r--r--system/database/DB_driver.php1
6 files changed, 9 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index 13833d1ee..f5cdbc98b 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,7 @@
This file lists major, incompatible or otherwise important changes, you should look at it after every update.
NEXT
+ - Fix PHP 8.2 deprecation warnings
4.0.0 2022-04-10
- BREAKING CHANGE: Minimum required PHP version is now >= 7
diff --git a/system/core/Controller.php b/system/core/Controller.php
index aeccd60ee..ac7a0566a 100644
--- a/system/core/Controller.php
+++ b/system/core/Controller.php
@@ -50,6 +50,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
* @author EllisLab Dev Team
* @link https://codeigniter.com/userguide3/general/controllers.html
*/
+#[\AllowDynamicProperties]
class CI_Controller {
/**
diff --git a/system/core/Loader.php b/system/core/Loader.php
index a70487e84..9f0ae4159 100644
--- a/system/core/Loader.php
+++ b/system/core/Loader.php
@@ -49,6 +49,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
* @author EllisLab Dev Team
* @link https://codeigniter.com/userguide3/libraries/loader.html
*/
+#[\AllowDynamicProperties]
class CI_Loader {
// All these are set automatically. Don't mess with them.
diff --git a/system/core/Router.php b/system/core/Router.php
index ab1f44e0e..1267afeb9 100644
--- a/system/core/Router.php
+++ b/system/core/Router.php
@@ -114,6 +114,9 @@ class CI_Router {
// --------------------------------------------------------------------
+
+ public $uri;
+
/**
* Class constructor
*
diff --git a/system/core/URI.php b/system/core/URI.php
index 6a55439f7..55e872163 100644
--- a/system/core/URI.php
+++ b/system/core/URI.php
@@ -92,6 +92,8 @@ class CI_URI {
*/
protected $_permitted_uri_chars;
+ public $config;
+
/**
* Class constructor
*
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 522f1bb92..031e0edcd 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -51,6 +51,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
* @author EllisLab Dev Team
* @link https://codeigniter.com/userguide3/database/
*/
+#[\AllowDynamicProperties]
abstract class CI_DB_driver {
/**