Add compatibility with php 8.2

This commit is contained in:
Beu
2023-01-17 10:06:56 +01:00
parent 16889f1a6a
commit 9e8432999b
8 changed files with 25 additions and 4 deletions

View File

@ -48,6 +48,8 @@ class ElementBuilder {
/**
* Private Properties
*/
/** @var ManiaControl $maniaControl */
private $maniaControl = null;
/** @var array $actions */
private $actions = array();
/** @var array $columns */
@ -173,6 +175,7 @@ class ElementBuilder {
* @param float $textSize
*/
public function buildKarmaGauge($map, $width, $height, $textSize = 0.9) {
/** @var \MCTeam\KarmaPlugin $karmaPlugin */
$karmaPlugin = $this->maniaControl->getPluginManager()->getPlugin(self::DEFAULT_KARMA_PLUGIN);
if (!$karmaPlugin) {
return null;