Null pointer exception fixed by card conversion