forked from rosebudai/OpenRCT2-Web
Handle nullptr for object when getting track designs
This commit is contained in:
1 parent
e1ace9528d
commit
60cb84fd9d
1 file changed
+2
-2
@@ -374,13 +374,13 @@ extern "C"
|
||||
size_t track_repository_get_count_for_ride(uint8 rideType, const utf8 * entry)
|
||||
{
|
||||
ITrackDesignRepository * repo = GetTrackDesignRepository();
|
||||
return repo->GetCountForObjectEntry(rideType, entry);
|
||||
return repo->GetCountForObjectEntry(rideType, String::ToStd(entry));
|
||||
}
|
||||
|
||||
size_t track_repository_get_items_for_ride(track_design_file_ref * * outRefs, uint8 rideType, const utf8 * entry)
|
||||
{
|
||||
ITrackDesignRepository * repo = GetTrackDesignRepository();
|
||||
return repo->GetItemsForObjectEntry(outRefs, rideType, entry);
|
||||
return repo->GetItemsForObjectEntry(outRefs, rideType, String::ToStd(entry));
|
||||
}
|
||||
|
||||
bool track_repository_delete(const utf8 * path)
|
||||
|
||||
Reference in new issue
Block a user