don't use parseint to determine selected year
cleanup and save state bugfix