Return error when body is empty

Fixes unhandled exception when body is null
Merge pull request #2 from 7eggs/master

Return error when body is empty