Bug #11056
findOneBy*() methods should return NULL if no item was found
| Status: | Resolved | Start date: | 2010-11-24 | |
|---|---|---|---|---|
| Priority: | Should have | Due date: | ||
| Assignee: | Robert Lemke | % Done: | 100% |
|
| Category: | Persistence | |||
| Target version: | TYPO3 Flow Base Distribution - 1.0 alpha 14 | |||
| PHP Version: | Complexity: | |||
| Has patch: | FLOW3 version affected: | |||
| Votes: | 0 |
Description
Currently all findOneBy*() methods of repositories return FALSE, if no records where found. As discussed this should be changed to NULL as done in Extbase (see #10958).
Related issues
| related to Extbase MVC Framework - Task #10958: findOneBy*() methods should return NULL if no item was found | Resolved | 2010-11-19 |
Associated revisions
[!!!][~TASK] FLOW3 (Persistence): Make getFirst() return NULL on empty result
The QueryResult::getFirst() method – and consequently also the repository's
findOneBy*() method – returned FALSE if the result set was empty. Because
this is contrary to the conventions elsewhere in FLOW3, this changes the
behavior of getFirst() to return NULL instead.
Change-Id: Icee8712ee9d610f629b7703212dbd3920fa44c1d
Resolves: #11056
History
Updated by Robert Lemke over 2 years ago
- Assignee changed from Bastian Waidelich to Robert Lemke
- Target version set to 1.0 alpha 14
Updated by Robert Lemke over 2 years ago
- Status changed from Accepted to Under Review
- % Done changed from 0 to 100
Updated by Robert Lemke over 2 years ago
- Status changed from Under Review to Resolved
Applied in changeset 86305942ab4b150659b72fd96146f9e6e7802e00.