Use Buffer.isBuffer to ensure we received a valid buffer
Added example
Additional modules required for example
gendocs
Bump version to 0.4.2