Currently, there are two validations on the backend exist for creating file extensions:
1. Duplicate file extensions
2. Invalid file extension
Now they are executed in the order specified above which may lead to the wrong results.
Steps to reproduce:
1. .csv file extension already exists on the server. Make POST request to data-import/fileExtensions endpoint with the following body
The problem is the extension field which has surrounding spaces.
The invalid file extension error returns from the server.
The duplication error returns from the server.