Protect against null prototypes
Support undefined prototypes
Merge pull request #70 from wpreul/master

Protect against null prototypes