mirror of
https://github.com/pelican-dev/panel.git
synced 2026-05-04 18:00:48 +03:00
Make sure custom pages/relations don't override default pages/relations (#2099)
This commit is contained in:
@@ -24,6 +24,6 @@ trait CanCustomizePages
|
||||
/** @return array<string, PageRegistration> */
|
||||
public static function getPages(): array
|
||||
{
|
||||
return array_unique(array_merge(static::getDefaultPages(), static::$customPages), SORT_REGULAR);
|
||||
return array_unique(array_merge(static::$customPages, static::getDefaultPages()), SORT_REGULAR);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,6 +23,6 @@ trait CanCustomizeRelations
|
||||
/** @return class-string<RelationManager>[] */
|
||||
public static function getRelations(): array
|
||||
{
|
||||
return array_unique(array_merge(static::getDefaultRelations(), static::$customRelations));
|
||||
return array_unique(array_merge(static::$customRelations, static::getDefaultRelations()));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user