Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
4rthem committed Nov 18, 2024
1 parent 51edc61 commit ce0e489
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions databox/api/src/Integration/RemoveBg/RemoveBgClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,11 @@ public function getBgRemoved(File $file, string $apiKey): string
}
fclose($fileHandler);
} catch (\Throwable $e) {
fclose($fileHandler);
@unlink($cacheFile);
if (isset($fileHandler)) {
fclose($fileHandler);
@unlink($cacheFile);
}

throw $e;
}

Expand Down

0 comments on commit ce0e489

Please sign in to comment.