<?php
/**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2022, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
* Returns the list of user defined tags (e.g. #Friendica)
*
* @return array
- *
* @throws \Exception
*/
- public static function getUserTags()
+ public static function getUserTags(): array
{
$termsStmt = DBA::p("SELECT DISTINCT(`term`) FROM `search`");
$tags = [];
while ($term = DBA::fetch($termsStmt)) {
- $tags[] = trim($term['term'], '#');
+ $tags[] = trim(mb_strtolower($term['term']), '#');
}
-
+ DBA::close($termsStmt);
return $tags;
}
}