- Some work done on correcting LDAP package compatibility

This commit is contained in:
mcndave committed 2021-03-09 15:25:46 +00:00
1 parent 71de0a8ac1
commit e3d0e45a4e
13 files changed
+110 -22

No files matched your search

@@ -0,0 +1,22 @@
<?php
namespace Ulmus\SearchRequest;
use Psr\Http\Message\ServerRequestInterface;
trait SearchRequestConstructorTrait
{
public function __construct(array $parameters = [])
{
$this->fromArray($parameters);
}
public function fromArray(array $data): self
{
foreach(array_filter($data, fn($e) => $e !== "") as $key => $value) {
$this->$key = $value;
}
return $this;
}
}