Fix crash with The Monarch

This commit is contained in:
tool4EvEr
2021-07-31 19:21:45 +02:00
parent cb7d8e572c
commit 168cc31955
2 changed files with 3 additions and 3 deletions

View File

@@ -156,7 +156,7 @@ public class ImageCache {
IPaperCard ipc = null;
boolean altState = imageKey.endsWith(ImageKeys.BACKFACE_POSTFIX);
if(altState)
if (altState)
imageKey = imageKey.substring(0, imageKey.length() - ImageKeys.BACKFACE_POSTFIX.length());
if (imageKey.startsWith(ImageKeys.CARD_PREFIX)) {
PaperCard pc = ImageUtil.getPaperCardFromImageKey(imageKey);
@@ -165,7 +165,7 @@ public class ImageCache {
if (StringUtils.isBlank(imageKey)) {
return _defaultImage;
}
} else if (imageKey.startsWith(ImageKeys.TOKEN_PREFIX)) {
} else if (imageKey.startsWith(ImageKeys.TOKEN_PREFIX) && cardView.isToken()) {
ipc = ImageUtil.getPaperTokenFromImageKey(imageKey);
}