modules/OSSMailScanner/scanneractions/BindVendors.php
Avoid unused parameters such as '$moduleName'. Open
Open
public function process(OSSMail_Mail_Model $mail, $moduleName = 'Vendors')
- Read upRead up
- Exclude checks
UnusedFormalParameter
Since: 0.2
Avoid passing parameters to methods or constructors and then not using those parameters.
Example
class Foo
{
private function bar($howdy)
{
// $howdy is not used
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter
Each class must be in a namespace of at least one level (a top-level vendor name) Open
Open
class OSSMailScanner_BindVendors_ScannerAction extends OSSMailScanner_EmailScannerAction_Model
- Exclude checks
The class OSSMailScanner_BindVendors_ScannerAction is not named in CamelCase. Open
Open
class OSSMailScanner_BindVendors_ScannerAction extends OSSMailScanner_EmailScannerAction_Model
{
public function process(OSSMail_Mail_Model $mail, $moduleName = 'Vendors')
{
return parent::process($mail, 'Vendors');
- Read upRead up
- Exclude checks
CamelCaseClassName
Since: 0.2
It is considered best practice to use the CamelCase notation to name classes.
Example
class class_name {
}
Source
Spaces must be used to indent lines; tabs are not allowed Open
Open
return parent::process($mail, 'Vendors');
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
public function process(OSSMail_Mail_Model $mail, $moduleName = 'Vendors')
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
{
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
Open
}
- Exclude checks
Class name "OSSMailScanner_BindVendors_ScannerAction" is not in camel caps format Open
Open
class OSSMailScanner_BindVendors_ScannerAction extends OSSMailScanner_EmailScannerAction_Model
- Exclude checks