Change to and from to use strings or arrays

This commit is contained in:
Oliver Davies 2017-12-30 10:49:31 +00:00
parent 02dddbdaf6
commit 9097da2972
3 changed files with 12 additions and 12 deletions

View file

@ -20,21 +20,21 @@ class Filter
return $this;
}
public function from()
public function from($values)
{
$this->properties['from'] = collect(func_get_args())
->map(function ($address) {
return trim($address);
$this->properties['from'] = collect($values)
->map(function ($value) {
return trim($value);
})->all();
return $this;
}
public function to()
public function to($values)
{
$this->properties['to'] = collect(func_get_args())
->map(function ($address) {
return trim($address);
$this->properties['to'] = collect($values)
->map(function ($value) {
return trim($value);
})->all();
return $this;