Permalink
Browse files

Fix: using the "with" option in ParamConverters triggered a notice

The following notice was triggered:

  Runtime Notice: Only variables should be passed by reference in
  /home/vagrant/www/project/vendor/propel/propel-bundle/Propel/PropelBundle/Request/ParamConverter/PropelParamConverter.php
  line 193
  • Loading branch information...
1 parent 94c0d89 commit bc15b927572d3a517873bd5f333c6e392dce4a83 @K-Phoen K-Phoen committed Oct 31, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 Request/ParamConverter/PropelParamConverter.php
@@ -190,7 +190,8 @@ protected function findOneBy($classQuery, Request $request)
if (!$this->hasWith) {
return $query->findOne();
} else {
- return reset($query->find());
+ $results = $query->find();
+ return reset($results);
}
}

0 comments on commit bc15b92

Please sign in to comment.