Adding a null check to a section of the game animation code that causes a bizarre visual crash out when reloading at the wrong time
This commit is contained in:
@@ -255,7 +255,9 @@ var GameAnimations = Class.extend({
|
||||
|
||||
if (targetCardId != null) {
|
||||
var targetCardData = $(".card:cardId(" + targetCardId + ")").data("card");
|
||||
targetCardData.attachedCards.push(cardDiv);
|
||||
if(targetCardData != null) {
|
||||
targetCardData.attachedCards.push(cardDiv);
|
||||
}
|
||||
}
|
||||
|
||||
next();
|
||||
|
||||
Reference in New Issue
Block a user