Error callback on server error
Add error parameter to perform method callback
Merge pull request #21 from potomak/master

Error callback on server error