fixed minor things in cell states function
Merge remote-tracking branch 'origin/master'