diff --git a/app/src/main/java/protect/card_locker/LoyaltyCardViewActivity.java b/app/src/main/java/protect/card_locker/LoyaltyCardViewActivity.java index f62b7e84f..41566aa11 100644 --- a/app/src/main/java/protect/card_locker/LoyaltyCardViewActivity.java +++ b/app/src/main/java/protect/card_locker/LoyaltyCardViewActivity.java @@ -583,6 +583,11 @@ public class LoyaltyCardViewActivity extends CatimaAppCompatActivity implements } private void prevNextCard(boolean next) { + // If there are no other cards, don't bother switching + if (cardList == null || cardList.size() == 1) { + return; + } + // If we're in RTL layout, we want the "left" button to be "next" instead of "previous" // So we swap next around boolean transitionRight = next;