Skip to content

Commit

Permalink
fix #67 issue - optional paramater php8 warning (#69)
Browse files Browse the repository at this point in the history
Co-authored-by: Muhammad Asif <[email protected]>
  • Loading branch information
webwizo and Muhammad Asif authored Feb 18, 2021
1 parent 625236b commit a41af32
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/Compilers/Shortcode.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ class Shortcode implements Arrayable
* Constructor
*
* @param string $name
* @param array $attributes
* @param string $content
* @param array $attributes
*/
public function __construct($name, $attributes = [], $content)
public function __construct($name, $content, $attributes = [])
{
$this->name = $name;
$this->attributes = $attributes;
$this->content = $content;
$this->attributes = $attributes;
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Compilers/ShortcodeCompiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,8 @@ protected function compileShortcode($matches)
// return shortcode instance
return new Shortcode(
$this->getName(),
$attributes,
$this->getContent()
$this->getContent(),
$attributes
);
}

Expand Down

0 comments on commit a41af32

Please sign in to comment.