aboutsummaryrefslogtreecommitdiff
path: root/src/Handlers/ApiTagsHandler.php
blob: af9fb7b0771b88afd3bf58618c3af656fabdb6e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<?php


namespace Micropoly\Handlers;


use Micropoly\Env;
use Micropoly\Models\Tag;

class ApiTagsHandler extends JsonAPIHandler
{
    protected function handleAPIRequest(Env $env, array $variables): JsonAPIResult
    {
        return new JsonAPIResult(array_keys(Tag::getTagCounts($env->db())));
    }
}