Fixed xml serializer exception

Fixed try block from always throwing exceptions