aboutsummaryrefslogtreecommitdiff
path: root/ratatoeskr/main.php
diff options
context:
space:
mode:
authorLaria Carolin Chabowski <laria@laria.me>2020-09-21 21:21:30 +0200
committerLaria Carolin Chabowski <laria@laria.me>2020-09-21 21:30:57 +0200
commit7f4159ac258c501f9666efc465a78cb2aec9d177 (patch)
tree298b4943fb5cd7ecf5f6959bf1b6f47fbc6e557a /ratatoeskr/main.php
parent9834bfc4dc7f0bbf4020cebb43b03069592bc687 (diff)
downloadratatoeskr-cms-7f4159ac258c501f9666efc465a78cb2aec9d177.tar.gz
ratatoeskr-cms-7f4159ac258c501f9666efc465a78cb2aec9d177.tar.bz2
ratatoeskr-cms-7f4159ac258c501f9666efc465a78cb2aec9d177.zip
Code cleanup
- Remove unused variables - Remove unused utility functions - Asserting presence and typehinting global variables - Remove unused variables - Add missing global - Add parameter type constraint - Fix some references to nonexisting variables
Diffstat (limited to 'ratatoeskr/main.php')
-rw-r--r--ratatoeskr/main.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/ratatoeskr/main.php b/ratatoeskr/main.php
index 491c739..9bbe504 100644
--- a/ratatoeskr/main.php
+++ b/ratatoeskr/main.php
@@ -46,8 +46,6 @@ function _ratatoeskr()
{
global $backend_subactions, $ste, $url_handlers, $ratatoeskr_settings, $plugin_objs, $api_compat;
- $ts_start = microtime(true);
-
session_start();
db_connect();
clean_database();
@@ -60,6 +58,7 @@ function _ratatoeskr()
$activeplugins = array_filter(Plugin::all(), function ($plugin) {
return $plugin->active;
});
+ /** @var Plugin $plugin */
foreach ($activeplugins as $plugin) {
if (!in_array($plugin->api, $api_compat)) {
$plugin->active = false;
@@ -68,6 +67,7 @@ function _ratatoeskr()
}
eval($plugin->code);
+ /** @var RatatoeskrPlugin $plugin_obj */
$plugin_obj = new $plugin->classname($plugin->get_id());
if ($plugin->update) {
$plugin_obj->update();