GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

ContentBlock::plural_name()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace SheaDawson\Blocks\Model;
4
5
class ContentBlock extends Block
6
{
7
	private static $table_name = "ContentBlock";
0 ignored issues
show
Comprehensibility introduced by
Consider using a different property name as you override a private property of the parent class.
Loading history...
Unused Code introduced by
The property $table_name is not used and could be removed.

This check marks private properties in classes that are never used. Those properties can be removed.

Loading history...
8
9
    /**
10
     * If the singular name is set in a private static $singular_name, it cannot be changed using the translation files
11
     * for some reason. Fix it by defining a method that handles the translation.
12
     * @return string
13
     */
14
    public function singular_name()
15
    {
16
        return _t('ContentBlock.SINGULARNAME', 'Content Block');
17
    }
18
19
    /**
20
     * If the plural name is set in a private static $plural_name, it cannot be changed using the translation files
21
     * for some reason. Fix it by defining a method that handles the translation.
22
     * @return string
23
     */
24
    public function plural_name()
25
    {
26
        return _t('ContentBlock.PLURALNAME', 'Content Blocks');
27
    }
28
29
    private static $db = [
0 ignored issues
show
Comprehensibility introduced by
Consider using a different property name as you override a private property of the parent class.
Loading history...
Unused Code introduced by
The property $db is not used and could be removed.

This check marks private properties in classes that are never used. Those properties can be removed.

Loading history...
30
        'Content' => 'HTMLText',
31
    ];
32
33
	public function fieldLabels($includeRelations = true)
34
	{
35
		return array_merge(
36
			parent::fieldLabels($includeRelations),
37
			[
38
				'Content' => _t('Block.Content', 'Content'),
39
			]
40
		);
41
	}
42
}
43