add error handling
Merge pull request #2 from brettsanders/fix_up_user_resource

add error handling