diff --git a/metadata_backend/api/handlers/submission.py b/metadata_backend/api/handlers/submission.py index 85f0ce6d6..715a58ede 100644 --- a/metadata_backend/api/handlers/submission.py +++ b/metadata_backend/api/handlers/submission.py @@ -310,7 +310,7 @@ async def put_submission_path(self, req: Request) -> Response: JSONValidator(submission, "submission").validate for file in data: if "accessionId" not in file: - reason = f"Updating {submission_id} failed files requires accessionId." + reason = f"Updating {submission_id} failed. Files require an accessionId." LOG.error(reason) raise web.HTTPBadRequest(reason=reason) _file_accessionId = file.pop("accessionId") @@ -396,7 +396,7 @@ async def delete_submission_files(self, req: Request) -> Response: Body needs to contain a list of accessionId for files. - :param req: POST request with metadata schema in the body + :param req: DELETE request :returns: HTTP No Content response """ submission_id = req.match_info["submissionId"] diff --git a/metadata_backend/database/db_service.py b/metadata_backend/database/db_service.py index d3bd0ac35..143d367b2 100644 --- a/metadata_backend/database/db_service.py +++ b/metadata_backend/database/db_service.py @@ -269,7 +269,7 @@ async def remove(self, collection: str, accession_id: str, data_to_be_removed: U :param accession_id: ID of the object/submission/user to be updated :param data_to_be_removed: str or JSON representing the data that should be updated to removed. - :returns: JSON after remove if operaation was successful + :returns: JSON after remove if operation was successful """ id_key = self._get_id_key(collection) find_by_id = {id_key: accession_id} @@ -314,7 +314,7 @@ async def append( :param data_to_be_addded: str or JSON representing the data that should be updated to removed. :param upsert: If the document does not exist add it - :returns: JSON after remove if operaation was successful + :returns: JSON after remove if operation was successful """ id_key = self._get_id_key(collection) find_by_id = {id_key: accession_id}