Skip to content

Commit f85d9b1

Browse files
committed
Remove unnecessary conditional
It shouldn't be necessary to preserve existing validation errors on an entry when it is updated via the API.
1 parent 81586e6 commit f85d9b1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

app/controllers/v1/submission_entries_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def update
1818
submission_file = SubmissionFile.find(params[:file_id])
1919
entry = submission_file.entries.find(params[:id])
2020
entry.aasm.current_state = submission_entry_params[:status]
21-
entry.validation_errors = submission_entry_params[:validation_errors] if submission_entry_params[:validation_errors]
21+
entry.validation_errors = submission_entry_params[:validation_errors]
2222

2323
if entry.save
2424
head :no_content

0 commit comments

Comments
 (0)