Fix trait usage
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
28fd18de43
commit
e8f5c21db9
|
@ -74,8 +74,7 @@ class AdminSettingsController extends Controller {
|
|||
* @param string $section
|
||||
* @return array
|
||||
*/
|
||||
private function getSettings($section) {
|
||||
// PhpStorm shows this as unused, but is required by CommonSettingsTrait
|
||||
protected function getSettings($section) {
|
||||
$settings = $this->settingsManager->getAdminSettings($section);
|
||||
$formatted = $this->formatSettings($settings);
|
||||
if($section === 'additional') {
|
||||
|
|
|
@ -119,5 +119,5 @@ trait CommonSettingsTrait {
|
|||
return new TemplateResponse('settings', 'settings/frame', $templateParams);
|
||||
}
|
||||
|
||||
abstract public function getSettings($section);
|
||||
abstract protected function getSettings($section);
|
||||
}
|
||||
|
|
|
@ -31,9 +31,7 @@ use OCP\Settings\IManager as ISettingsManager;
|
|||
use OCP\Template;
|
||||
|
||||
class PersonalSettingsController extends Controller {
|
||||
use CommonSettingsTrait {
|
||||
getSettings as private;
|
||||
}
|
||||
use CommonSettingsTrait;
|
||||
|
||||
/** @var INavigationManager */
|
||||
private $navigationManager;
|
||||
|
@ -66,8 +64,7 @@ class PersonalSettingsController extends Controller {
|
|||
* @param string $section
|
||||
* @return array
|
||||
*/
|
||||
private function getSettings($section) {
|
||||
// PhpStorm shows this as unused, but is required by CommonSettingsTrait
|
||||
protected function getSettings($section) {
|
||||
$settings = $this->settingsManager->getPersonalSettings($section);
|
||||
$formatted = $this->formatSettings($settings);
|
||||
if($section === 'additional') {
|
||||
|
|
Loading…
Reference in New Issue