Add DDD classes for Mastodon\Field entity
This commit is contained in:
20
src/Collection/Api/Mastodon/Fields.php
Normal file
20
src/Collection/Api/Mastodon/Fields.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace Friendica\Collection\Api\Mastodon;
|
||||
|
||||
use Friendica\Api\Entity\Mastodon\Field;
|
||||
use Friendica\BaseCollection;
|
||||
|
||||
class Fields extends BaseCollection
|
||||
{
|
||||
/**
|
||||
* @param Field[] $entities
|
||||
* @param int|null $totalCount
|
||||
*/
|
||||
public function __construct(array $entities = [], int $totalCount = null)
|
||||
{
|
||||
parent::__construct($entities);
|
||||
|
||||
$this->totalCount = $totalCount ?? count($entities);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user