Fixed some minor buggs
Merge pull request #366 from reem-utils/sergi_branch

Fixed some minor buggs