Skip to content

Commit

Permalink
Fixed missing null definition in method argument.
Browse files Browse the repository at this point in the history
  • Loading branch information
hexydec committed Nov 25, 2024
1 parent d80b212 commit 8a46621
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/cssdoc.php
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ public function open(string $url, $context = null, ?string &$error = null) : str
* @param ?string &$error A reference to any user error that is generated
* @return bool Whether the input CSS was parsed
*/
public function load(string $css, string $charset = null, ?string &$error = null) : bool {
public function load(string $css, ?string $charset = null, ?string &$error = null) : bool {

// detect the charset
if ($charset || ($charset = $this->getCharsetFromCss($css)) !== null) {
Expand Down Expand Up @@ -307,7 +307,7 @@ public function compile(array $options = []) : ?string {
* @param array $options An array indicating output options, this is merged with cssdoc::$output
* @return string|false The compiled CSS, or false if the file could not be saved
*/
public function save(string $file = null, array $options = []) : string|false {
public function save(?string $file = null, array $options = []) : string|false {
$css = $this->compile($options);

// save file
Expand Down

0 comments on commit 8a46621

Please sign in to comment.