If an import happens to fail the dialog promise never resolves.
This is because `numberOfStudiesFailed` is incremented on error but `numberOfStudiesImported` is not, so the branch to resolve or reject is never taken.
* fix: first time uploadMessage called with undefined as parameter
- During uploading DICOMs the first time the function is called with
no parameter -> this leads to the whole upload to be crashing
* Write the function shorter...