Fixes the issue with selected card indices saving to the database - mrracine