Jump to content

Bug on \IPS\Helpers\Table\Table


Recommended Posts

Posted

Tryingo to extend \IPS\Notification\Table, which extends \IPS\Helpers\Table\Table:

	/**
	 * Constructor
	 *
	 * @param	\IPS\Http\Url	Base URL
	 * @return	void
	 */
	public function __construct( \IPS\Http\Url $url=NULL )
	{
		/* Init */	
		parent::__construct( $url );
	}

This simple hook returns an error if the user has no notiications:

Quote

Whoops\Exception\ErrorException: count(): Parameter must be an array or an object that implements Countable (2)
#0 C:\wamp64\www\test\system\Helpers\Table\Table.php(521): Whoops\Run->handleError(2, 'count(): Parame...', 'C:\\wamp64\\www\\t...', 521, Array)
#1 C:\wamp64\www\test\applications\core\modules\front\system\notifications.php(63): IPS\Helpers\Table\_Table->__toString()
#2 C:\wamp64\www\test\system\Dispatcher\Controller.php(96): IPS\core\modules\front\system\_notifications->manage()
#3 C:\wamp64\www\test\system\Dispatcher\Dispatcher.php(152): IPS\Dispatcher\_Controller->execute()
#4 C:\wamp64\www\test\index.php(13): IPS\_Dispatcher->run()
#5 {main}

Works fine if I have notifications.

Posted
1 hour ago, newbie LAC said:

Exclude E_WARNING from error_reporting

Time by time during development I get warnings and should disable them.

this is a problem on the IPS side, it should be reported, you shouldn't suppress anything from error_reporting. this issue can be reproduced without a hook. they are return NULL for getRows if it is empty. 

Posted
40 minutes ago, CodingJungle said:

it should be reported

Yes, this is a report. I gave up from reporting bugs via ticket. They always sent back to this forum, so...

EDIT: I mean development bug that has a 3rd-party behind, even when it's a CORE bug.

Posted
5 minutes ago, CodingJungle said:

this is a problem on the IPS side, it should be reported, you shouldn't suppress anything from error_reporting. this issue can be reproduced without a hook. they are return NULL for getRows if it is empty. 

I haven't time report every warning. IPS should enable ALL levels when they development.

Posted
On 7/20/2019 at 8:45 AM, newbie LAC said:

I haven't time report every warning. IPS should enable ALL levels when they development.

During developing, all error levels are enabled.

 

I'll take a look at the error for an upcoming maintenance release.

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...