raml-php-parser
raml-php-parser copied to clipboard
ApiDefinition: Fix Deprecated warning on empty schema
According to line 815, empty schema is supported. This update avoids passing null when $this->baseUri doesn't have a scheme/schema from \parse_url($this->baseUri, PHP_URL_SCHEME) to mb_strtoupper.
To reproduce:
- Don't set a
baseUriin your RAML configuration ($this->baseUriisnull). - Set a
baseUriwithout schema, likebaseUri: //api.example.com/{version}.
Fix PHP Deprecated: mb_strtoupper(): Passing null to parameter #1 ($string) of type string is deprecated in /Users/adriendupuis/www/developer-documentation/tools/raml2html/vendor/raml-org/raml-php-parser/src/ApiDefinition.php on line 813