1
0
mirror of https://github.com/wbbaddons/Tims-Chat.git synced 2024-10-31 14:10:08 +00:00

Fix PHP 5.3 compatability

This commit is contained in:
Maximilian Mader 2013-06-24 18:09:31 +02:00
parent a8fb9c35f5
commit 1b077719b8

View File

@ -84,12 +84,14 @@ class ChatPage extends \wcf\page\AbstractPage {
public function assignVariables() { public function assignVariables() {
parent::assignVariables(); parent::assignVariables();
$reflection = new \ReflectionClass('\chat\data\message\Message');
WCF::getTPL()->assign(array( WCF::getTPL()->assign(array(
'room' => $this->room, 'room' => $this->room,
'roomID' => $this->roomID, 'roomID' => $this->roomID,
'rooms' => $this->rooms, 'rooms' => $this->rooms,
'commands' => $this->commands, 'commands' => $this->commands,
'messageTypes' => (new \ReflectionClass('\chat\data\message\Message'))->getConstants(), 'messageTypes' => $reflection->getConstants(),
'defaultSmilies' => $this->defaultSmilies, 'defaultSmilies' => $this->defaultSmilies,
'smileyCategories' => $this->smileyCategories, 'smileyCategories' => $this->smileyCategories,
'sidebarCollapsed' => \wcf\system\user\collapsible\content\UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'be.bastelstu.chat.ChatPage'), 'sidebarCollapsed' => \wcf\system\user\collapsible\content\UserCollapsibleContentHandler::getInstance()->isCollapsed('com.woltlab.wcf.collapsibleSidebar', 'be.bastelstu.chat.ChatPage'),