UnionOfRAD / lithium

li₃ is the fast, flexible and most RAD development framework for PHP
http://li3.me
BSD 3-Clause "New" or "Revised" License
1.22k stars 238 forks source link

I'm getting an Uncaught TypeError from Lithium. Seems to be caused by a RecordSet object but I can't find why. #1331

Closed niel closed 1 year ago

niel commented 6 years ago

[04-Jun-2018 09:57:54 Europe/London] PHP Fatal error: Uncaught TypeError: Argument 1 passed to app\models\Groups::create() must be of the type array, boolean given, called in /home/niel/dev/www/test/libraries/lithium/data/collection/RecordSet.php on line 106 and defined in /home/niel/dev/www/test/app/models/Groups.php:94 Stack trace:

0 /home/niel/dev/www/test/libraries/lithium/data/collection/RecordSet.php(106): app\models\Groups::create(false, Array)

1 /home/niel/dev/www/test/libraries/lithium/data/Collection.php(267): lithium\data\collection\RecordSet->_set(false, 'active')

2 /home/niel/dev/www/test/libraries/lithium/data/Collection.php(225): lithium\data\Collection->offsetSet('active', false)

3 /home/niel/dev/www/test/libraries/lithium/data/Collection.php(146): lithium\data\Collection->set(Array)

4 /home/niel/dev/www/test/libraries/lithium/data/collection/RecordSet.php(65): lithium\data\Collection->_init()

5 /home/niel/dev/www/test/libraries/lithium/core/Object.php(84): lithium\data\collection\RecordSet->_ in /home/niel/dev/www/test/app/models/Groups.php on line 94

I've no idea what is going on here, as no part of the code should be creating any entries in the DB at this part I'm testing.

nateabele commented 1 year ago

@niel Been a while... I don't suppose you're still experiencing this? Any chance you could post a reproduction?

niel commented 1 year ago

I stopped using Lithium because of the drop in development pace. Nice to see you involved again @nateabele

nateabele commented 1 year ago

No worries. Take care!