Skip to content

Commit

Permalink
Merge pull request #54 from quintly/fixSreingParser
Browse files Browse the repository at this point in the history
changed null to string
  • Loading branch information
mpscholten authored Jun 19, 2020
2 parents 5458e9b + 501ad6c commit de69c3b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/StringParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function defaultsTo($defaultValue)
* @param string $invalidValueMessage
* @param string $notFoundMessage
*
* @return null
* @return string
*/
public function required($invalidValueMessage = null, $notFoundMessage = null)
{
Expand All @@ -51,7 +51,7 @@ public function defaultsToIfEmpty($defaultValue)
if ($this->value === '') {
return $defaultValue;
}

return $this->defaultsTo($defaultValue);
}

Expand All @@ -74,7 +74,7 @@ public function leftTrim()
{
return new TrimParser($this->config, $this->name, $this->value, TrimParser::LEFT_TRIM);
}

public function rightTrim()
{
return new TrimParser($this->config, $this->name, $this->value, TrimParser::RIGHT_TRIM);
Expand Down

0 comments on commit de69c3b

Please sign in to comment.