* @param array $conditions Array of fields for conditions
* @param array $params Array of several parameters
*
- * @return boolean|array
+ * @return array
*
* @throws \Exception
* @see \Friendica\Database\DBA::selectToArray
$fields = self::getFields();
}
- $r = DBA::selectToArray('attach', $fields, $conditions, $params);
+ return DBA::selectToArray('attach', $fields, $conditions, $params);
}
/**
$result = self::select($fields, $condition, $params);
if (is_bool($result)) {
- return $result;
- }
-
- $data = [];
- while ($row = self::fetch($result)) {
- $data[] = $row;
+ return [];
}
- DBA::close($result);
- return $data;
+ return DBA::toArray($result);
}
/**