Skip to content

Commit

Permalink
Fixing the entities method
Browse files Browse the repository at this point in the history
  • Loading branch information
arcanedev-maroc committed May 23, 2018
1 parent 4ed9d0e commit f39f4db
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/Contracts/HtmlBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,11 @@ interface HtmlBuilder
* Convert an HTML string to entities.
*
* @param string $value
* @param bool $doubleEncode
*
* @return string
*/
public function entities($value);
public function entities($value, $doubleEncode = false);

/**
* Convert all applicable characters to HTML entities.
Expand Down
5 changes: 3 additions & 2 deletions src/HtmlBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,13 @@ public function __construct(UrlGenerator $url = null)
* Convert an HTML string to entities.
*
* @param string $value
* @param bool $doubleEncode
*
* @return string
*/
public function entities($value)
public function entities($value, $doubleEncode = false)
{
return e($value);
return e($value, $doubleEncode);
}

/**
Expand Down

0 comments on commit f39f4db

Please sign in to comment.