clusters: fix linting (ugh)

Signed-off-by: Varun Patil <radialapps@gmail.com>
pull/767/head
Varun Patil 2023-08-03 19:56:32 -07:00
parent 66f9616942
commit 46a15a16eb
6 changed files with 10 additions and 9 deletions

View File

@ -87,7 +87,7 @@ class AlbumsBackend extends Backend
$this->tq->allowEmptyRoot();
}
protected function getClustersI(int $fileid = 0): array
public function getClustersInternal(int $fileid = 0): array
{
// Run actual queries
$list = [];

View File

@ -66,7 +66,7 @@ abstract class Backend
*
* @param int $fileid Filter clusters by file ID (optional)
*/
abstract protected function getClustersI(int $fileid = 0): array;
abstract public function getClustersInternal(int $fileid = 0): array;
/**
* Get a cluster ID for the given cluster.
@ -134,8 +134,9 @@ abstract class Backend
*
* @param int $fileid Filter clusters by file ID (optional)
*/
public final function getClusters(int $fileid): array {
$list = $this->getClustersI($fileid);
final public function getClusters(int $fileid): array
{
$list = $this->getClustersInternal($fileid);
foreach ($list as &$cluster) {
$cluster['cluster_id'] = $this->getClusterId($cluster);
@ -148,7 +149,7 @@ abstract class Backend
/**
* Register the backend. Do not override.
*/
public static final function register(): void
final public static function register(): void
{
Manager::register(static::clusterType(), static::class);
}

View File

@ -123,7 +123,7 @@ class FaceRecognitionBackend extends Backend
unset($row['face_x'], $row['face_y'], $row['face_w'], $row['face_h'], $row['image_height'], $row['image_width']);
}
protected function getClustersI(int $fileid = 0): array
public function getClustersInternal(int $fileid = 0): array
{
if ($fileid) {
throw new \Exception('FaceRecognitionBackend: fileid filter not implemented');

View File

@ -63,7 +63,7 @@ class PlacesBackend extends Backend
));
}
protected function getClustersI(int $fileid = 0): array
public function getClustersInternal(int $fileid = 0): array
{
if ($fileid) {
throw new \Exception('PlacesBackend: fileid filter not implemented');

View File

@ -129,7 +129,7 @@ class RecognizeBackend extends Backend
unset($row['face_w'], $row['face_h'], $row['face_x'], $row['face_y']);
}
protected function getClustersI(int $fileid = 0): array
public function getClustersInternal(int $fileid = 0): array
{
$query = $this->tq->getBuilder();

View File

@ -67,7 +67,7 @@ class TagsBackend extends Backend
));
}
protected function getClustersI(int $fileid = 0): array
public function getClustersInternal(int $fileid = 0): array
{
if ($fileid) {
throw new \Exception('TagsBackend: fileid filter not implemented');