Exemple #1
0
    def get(self, name):
        try:
            project = self.get_project_interactor.set_params(
                name=name).execute()
        except EntityDoesNotExist:
            body = {"error": "Project does not exist!"}
            status = HTTPStatus.NOT_FOUND
        else:
            body = ProjectSerializer.serialize(project)
            status = HTTPStatus.OK

        return body, status