Browse Source

Updated the example code

tags/v13.2.0
Cédric Belin 3 months ago
parent
commit
ce38b59bf9
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      example/main.php

+ 3
- 3
example/main.php View File

@@ -6,11 +6,11 @@ function main(): void {
try {
$coverage = file_get_contents("/path/to/coverage.report");
(new Client)->upload($coverage);
echo "The report was sent successfully.";
print "The report was sent successfully.";
}

catch (Throwable $e) {
echo "An error occurred: ", $e->getMessage();
if ($e instanceof ClientException) echo "From: ", $e->getUri(), PHP_EOL;
print "An error occurred: {$e->getMessage()}" . PHP_EOL;
if ($e instanceof ClientException) print "From: {$e->getUri()}" . PHP_EOL;
}
}

Loading…
Cancel
Save