correct card update code