mirror of
https://github.com/opdavies/gmail-filter-builder.git
synced 2025-09-04 12:45:34 +01:00
Change to and from to use strings or arrays
This commit is contained in:
parent
02dddbdaf6
commit
9097da2972
3 changed files with 12 additions and 12 deletions
|
@ -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;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue