UnionOfRAD/lithium — pull request #1081 by minhna (2014-04-23 16:15:02+00:00)
Title: Update Result.php

catch exception: BadValue bad skip value in query.
When I query and it returns the empty result, if I try to call `count()` or apply a `foreach` loop, it throw out that exception.
I have no idea why the `$this->_resource->hasNext()` function return true, but `$this->_resource->getNext();` throw out exception.

Example:
```php
$users = Users::find('all', array('conditions'=>array('email'=>'abc@xyz.com')));
if($users->count()){ //exception throw out if no user has that email
//do something here
}
```