Fixes TypeError if dict value is not a string
adds missing nonetype check
Merge pull request #15 from Birdback/puts-dict-fix

Fixes TypeError if dict value is not a string