SubsiteMenuExtension   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 5
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 5
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A subsiteCMSShowInMenu() 0 3 1
1
<?php
2
3
namespace SilverStripe\Subsites\Extensions;
4
5
use SilverStripe\Core\Extension;
6
7
/*
8
 * Simple extension to show admins in the menu of subsites.
9
 * If an admin area should be available to a subsite, you can attach
10
 * this class to your admin in config. eg:
11
 *
12
 * 		MyAdmin::add_extension('SubsiteMenuExtension');
13
 *
14
 * Or you can include the subsiteCMSShowInMenu function in your admin class and have it return true
15
 */
16
17
class SubsiteMenuExtension extends Extension
18
{
19
    public function subsiteCMSShowInMenu()
20
    {
21
        return true;
22
    }
23
}
24