User tests: Successful: Unsuccessful:
Fixes #33445
Status | New | ⇒ | Pending |
Category | ⇒ | Administration com_categories com_tags Libraries |
@joomdonation please move discussion of removing getIsEmptyState
content to #33466
This PR stands on its own to fix a specific issue, and works well.
Labels |
Added:
?
|
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2021-05-01 17:58:26 |
Closed_By | ⇒ | PhilETaylor |
@PhilETaylor @Bakual I think we should re-think about the implementation of method
getIsEmptyState
in our model classes. As of right now, we assume that the method is always called after getItems method (mean we have $query property already initialized somewhere)However, since it is a Public method, we could not assure that. For a public method like that, developer could call it anytime they want and not depend on the calling of other methods. For example, in any view class, if we call this command at the top:
We will get error below:
Call to a member function clear() on array
To implement this method properly, we can borrow
getTotal
method fromListModel
class.