3063 Posts in 864 Topics by 646 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 182 Views |
-
Bug in SQLQuery::lastRow()?

3 December 2012 at 11:12pm
Im working on a project and try to get the last element of a DataList:
$object->Childeren()->last();
If the list is empty, I get the following error:
[User Error] Uncaught InvalidArgumentException: SQLQuery::setLimit() only takes positive values
I have attached an image with the full output.
Is it possible that this is a bug or do I realy have to check if the list is empty before i call last()?
-
Re: Bug in SQLQuery::lastRow()?

5 December 2012 at 9:02pm
Might be good to write up a test case and submit a fix.
| 182 Views | ||
|
Page:
1
|
Go to Top |


