mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-04-10 19:15:13 +00:00
Fixed an issue where randomly selecting an empty custom collection could crash the application.
This commit is contained in:
parent
145cbf8df7
commit
5565170d93
|
@ -571,8 +571,7 @@ FileData* SystemData::getRandomGame(const FileData* currentGame)
|
||||||
// otherwise get a list of all the folder and file entries in the view.
|
// otherwise get a list of all the folder and file entries in the view.
|
||||||
if (currentGame && currentGame->getType() == FOLDER && currentGame->
|
if (currentGame && currentGame->getType() == FOLDER && currentGame->
|
||||||
getSystem()->isGroupedCustomCollection()) {
|
getSystem()->isGroupedCustomCollection()) {
|
||||||
gameList = ViewController::get()->getGameListView(mRootFolder->getSystem()).get()->
|
gameList = mRootFolder->getParent()->getChildrenListToDisplay();
|
||||||
getCursor()->getParent()->getParent()->getChildrenListToDisplay();
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
gameList = ViewController::get()->getGameListView(mRootFolder->
|
gameList = ViewController::get()->getGameListView(mRootFolder->
|
||||||
|
|
Loading…
Reference in a new issue