Update User.php

Added support for exception raising and exception logging otherwise i had no idea of what is going wrong