Added some Exceptions and handled them