packbackbooks/lti-1-3-php-library

View on GitHub
src/Concerns/Arrayable.php

Summary

Maintainability
A
0 mins
Test Coverage
A
100%
<?php

namespace Packback\Lti1p3\Concerns;

use Packback\Lti1p3\Helpers\Helpers;

trait Arrayable
{
    abstract public function getArray(): array;

    public function toArray(): array
    {
        return Helpers::filterOutNulls($this->getArray());
    }
}