Closed boelle closed 9 years ago
googled and found this link interesting... but not a clue how to "fix" my issue
http://stackoverflow.com/questions/1075534/cant-use-method-return-value-in-write-context
Seems that code is only supported by PHP 5.5 and higher.
Try changing said line into this:
$hasHelp = $details->getHelp();
if (empty($hasHelp))
worked :-D
thanks
I get an error when i start... error below
my config file:
<?php return array( 'server' => 'irc.freenode.org', 'port' => 6667, 'name' => 'phpbot', 'password' => '', 'nick' => 'phpbot', 'channels' => array( '#marlin-firmware', ), 'timezone' => 'Europe/Copenhagen', 'max_reconnects' => 1, 'prefix' => '!', 'log_file' => 'log.txt', 'commands' => array( 'Command\Say' => array(), 'Command\Weather' => array( 'yahooKey' => 'a', ), 'Command\Joke' => array(), 'Command\Ip' => array(), 'Command\Imdb' => array(), 'Command\Poke' => array(), 'Command\Topic' => array(), 'Command\Join' => array(), 'Command\Part' => array(), 'Command\Timeout' => array(), 'Command\Quit' => array(), 'Command\Restart' => array(), 'Command\Help' => array(), ), 'listeners' => array( 'Listener\Joins' => array(), ), 'hosts' => array( 'Add trusted hosts in here. Example: example@example.com if no ident server ~example@example.com', ), );
09.01.2015 - 14:28:43 [ INFO ] The following Command was added to the Bot: "Restart". PHP Fatal error: Can't use method return value in write context in /var/www/IRC-Bot-master/Classes/Command/Help.php on line 62