Revision 5b0832fc snf-cyclades-app/synnefo/api/util.py

b/snf-cyclades-app/synnefo/api/util.py
128 128
            servers = servers.select_for_update()
129 129
        vm = servers.get(id=server_id, userid=user_id)
130 130
        if non_deleted and vm.deleted:
131
            raise VirtualMachine.DeletedError
131
            raise faults.BadRequest("Server has been deleted.")
132 132
        if non_suspended and vm.suspended:
133 133
            raise faults.Forbidden("Administratively Suspended VM")
134 134
        return vm

Also available in: Unified diff