Fixed bug in deck model