Fixing bug 1215, duplicate user throws incorrect error

--HG--
extra : source : 25d5557856c345dad694cc0234734caf305f048d
Merge pull request #344 from einhverfr/master

Fixing bug 1215, duplicate user throws incorrect error