Skip to content

Commit

Permalink
Update Kabsa.php
Browse files Browse the repository at this point in the history
  • Loading branch information
BSN4 committed Mar 14, 2020
1 parent 1df74ac commit ea97aad
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Traits/Kabsa.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,17 @@

trait Kabsa
{
public function getRows()
{
return $this->rows;
}

public static function all($columns = [])
{
self::unguard();
$self = new self();
return Collection::make($self->rows ?? [])->map(function ($row) { return new self($row); });

return Collection::make($self->getRows() ?? [])->map(function ($row) { return new self($row); });
}

public function __call($method, $parameters)
Expand Down

0 comments on commit ea97aad

Please sign in to comment.