georgringer / news

TYPO3 Extension news
GNU General Public License v2.0
264 stars 358 forks source link

CountDemanded not work #2217

Closed KrohnMi closed 1 month ago

KrohnMi commented 11 months ago

Bug Report

Current Behavior I get the following error message when I try to determine the number of entries by a demand object

TYPO3\CMS\Extbase\Persistence\Generic\Query::logicalAnd(): Argument #1 must
      be of type TYPO3\CMS\Extbase\Persistence\Generic\Qom\ConstraintInterface, ar
      ray given, called in /var/www/vendor/georgringer/news/Classes/Domain/Reposit
      ory/AbstractDemandedRepository.php on line 181

Expected behavior/output That i get the number of entries

Environment

georgringer commented 11 months ago

add a comment at https://github.com/JAK0TA/news/commit/24160f4c6381c1426139044024e43a7dcfc42375, wanna test that?

KrohnMi commented 11 months ago

@georgringer Yes, I tested it, but I think we don't need it here anymore. The constraints are always set in the create query method.

valentin- commented 3 months ago

I'm experiencing the same issue using coundDemanded. The fix mentioned in https://github.com/JAK0TA/news/commit/24160f4c6381c1426139044024e43a7dcfc42375 works for me.