fix errors for bad cards