mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-27 04:43:54 +01:00
Fix bookmark crash fix (#2047)
* Fix bookmark crash fix * Fix check for bookmark creator
This commit is contained in:
parent
f2d271af37
commit
2e29f4f7f9
2 changed files with 2 additions and 2 deletions
|
|
@ -36,7 +36,7 @@ public class BookmarkPicturesController {
|
|||
for (Bookmark bookmark : bookmarks) {
|
||||
List<Media> tmpMedias = mediaWikiApi.searchImages(bookmark.getMediaName(), 0);
|
||||
for (Media m : tmpMedias) {
|
||||
if (m.getCreator().equals(bookmark.getMediaCreator())) {
|
||||
if (m.getCreator().trim().equals(bookmark.getMediaCreator().trim())) {
|
||||
medias.add(m);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -271,7 +271,7 @@ public class MediaDetailPagerFragment extends CommonsDaggerSupportFragment imple
|
|||
menu.clear(); // see http://stackoverflow.com/a/8495697/17865
|
||||
inflater.inflate(R.menu.fragment_image_detail, menu);
|
||||
if (pager != null) {
|
||||
MediaDetailProvider provider = (MediaDetailProvider) getParentFragment();
|
||||
MediaDetailProvider provider = getMediaDetailProvider();
|
||||
if(provider == null) {
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue