mirror of
https://github.com/friendica/friendica
synced 2025-05-07 14:24:09 +02:00
Cast field data when ATTR_EMULATE_PREPARES is enabled
This commit is contained in:
parent
f0d6f8c45e
commit
bd9f36622e
6 changed files with 102 additions and 9 deletions
|
@ -233,6 +233,8 @@ class Item
|
|||
return $row;
|
||||
}
|
||||
|
||||
$row = DBA::castFields('item', $row);
|
||||
|
||||
// ---------------------- Transform item structure data ----------------------
|
||||
|
||||
// We prefer the data from the user's contact over the public one
|
||||
|
@ -3024,7 +3026,7 @@ class Item
|
|||
return $recipients;
|
||||
}
|
||||
|
||||
public static function expire($uid, $days, $network = "", $force = false)
|
||||
public static function expire(int $uid, int $days, string $network = "", bool $force = false)
|
||||
{
|
||||
if (!$uid || ($days < 1)) {
|
||||
return;
|
||||
|
|
|
@ -517,7 +517,7 @@ class Tag
|
|||
* @return array
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function setGlobalTrendingHashtags(int $period, $limit = 10)
|
||||
public static function setGlobalTrendingHashtags(int $period, int $limit = 10)
|
||||
{
|
||||
$tagsStmt = DBA::p("SELECT `name` AS `term`, COUNT(*) AS `score`
|
||||
FROM `tag-search-view`
|
||||
|
@ -560,7 +560,7 @@ class Tag
|
|||
* @return array
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function setLocalTrendingHashtags(int $period, $limit = 10)
|
||||
public static function setLocalTrendingHashtags(int $period, int $limit = 10)
|
||||
{
|
||||
$tagsStmt = DBA::p("SELECT `name` AS `term`, COUNT(*) AS `score`
|
||||
FROM `tag-search-view`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue