1
0
Fork 0

Issue 10306: Improve local delivery

This commit is contained in:
Michael 2021-05-26 09:24:37 +00:00
commit 785f8124ed
8 changed files with 131 additions and 99 deletions

View file

@ -164,15 +164,16 @@ class Post
* @param array $fields
* @param array $condition
* @param array $params
* @param bool $user_mode true = post-user-view, false = post-view
* @return bool|array
* @throws \Exception
* @see DBA::select
*/
public static function selectFirst(array $fields = [], array $condition = [], $params = [])
public static function selectFirst(array $fields = [], array $condition = [], $params = [], bool $user_mode = true)
{
$params['limit'] = 1;
$result = self::select($fields, $condition, $params);
$result = self::select($fields, $condition, $params, $user_mode);
if (is_bool($result)) {
return $result;