Skip to content

Commit

Permalink
Merge pull request #654 from Pixilib/exploring-import-error
Browse files Browse the repository at this point in the history
Exploring import error
  • Loading branch information
salimkanoun committed Jun 11, 2023
2 parents 3fb250c + be1f5e5 commit d798e14
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions GaelO2/app/GaelO/Adapters/HttpClientAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,12 @@ public function requestUploadArrayDicom(string $method, string $uri, array $file
'rejected' => function (RequestException $exception, $index) {
$reason = "Error sending dicom to orthanc";
if ($exception->hasResponse()) {
$reason = $exception->getResponse()->getReasonPhrase();
$reason = $exception->getResponse()->getStatusCode();
} else {
$reason = $exception->getMessage();
}
// this is delivered each failed request
Log::error('DICOM Import Failed in Orthanc Temporary ' + $reason);
Log::error('DICOM Import Failed in Orthanc Temporary: ' + $reason);
},
]);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,7 @@ private function handleImportException(string $errorMessage, int $visitId, strin
$errorMessage
);

if (is_dir($unzipedPath)) Util::recursiveDirectoryDelete($unzipedPath);
//TODO temporary disable remove of unzip path
//if (is_dir($unzipedPath)) Util::recursiveDirectoryDelete($unzipedPath);
}
}

0 comments on commit d798e14

Please sign in to comment.