Skip to content

Commit

Permalink
Merge pull request #96 from yorickgirard/specify-exception-thrown
Browse files Browse the repository at this point in the history
Add exception in readFromJsonFile
  • Loading branch information
cebe committed Feb 16, 2021
2 parents b33d45e + 4dc7d45 commit 8397720
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Reader.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
use cebe\openapi\exceptions\IOException;
use cebe\openapi\exceptions\TypeErrorException;
use cebe\openapi\exceptions\UnresolvableReferenceException;
use cebe\openapi\json\InvalidJsonPointerSyntaxException;
use cebe\openapi\json\JsonPointer;
use cebe\openapi\spec\OpenApi;
use Symfony\Component\Yaml\Yaml;
Expand Down Expand Up @@ -78,6 +79,7 @@ public static function readFromYaml(string $yaml, string $baseType = OpenApi::cl
* @throws TypeErrorException in case invalid spec data is supplied.
* @throws UnresolvableReferenceException in case references could not be resolved.
* @throws IOException when the file is not readable.
* @throws InvalidJsonPointerSyntaxException in case an invalid JSON pointer string is passed to the spec references.
*/
public static function readFromJsonFile(string $fileName, string $baseType = OpenApi::class, $resolveReferences = true): SpecObjectInterface
{
Expand Down

0 comments on commit 8397720

Please sign in to comment.