mirror of
https://github.com/joomla-extensions/jedchecker.git
synced 2024-12-03 18:38:30 +00:00
unify displayed code lines
This commit is contained in:
parent
2c28bafe47
commit
2c2ea7da46
@ -184,6 +184,7 @@ class JedcheckerRulesGpl extends JEDcheckerRule
|
|||||||
{
|
{
|
||||||
// check the file is empty (i.e. comments-only)
|
// check the file is empty (i.e. comments-only)
|
||||||
$content = php_strip_whitespace($file);
|
$content = php_strip_whitespace($file);
|
||||||
|
|
||||||
if (preg_match('#^<\?php\s+$#', $content))
|
if (preg_match('#^<\?php\s+$#', $content))
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
@ -199,9 +200,11 @@ class JedcheckerRulesGpl extends JEDcheckerRule
|
|||||||
$line_no = substr_count($content, "\n", 0, $match[0][1]) + 1;
|
$line_no = substr_count($content, "\n", 0, $match[0][1]) + 1;
|
||||||
$this->report->addInfo(
|
$this->report->addInfo(
|
||||||
$file,
|
$file,
|
||||||
JText::_('COM_JEDCHECKER_PH1_LICENSE_FOUND') . ':' . '<strong>' . $match[0][0] . '</strong>',
|
JText::_('COM_JEDCHECKER_PH1_LICENSE_FOUND'),
|
||||||
$line_no
|
$line_no,
|
||||||
|
$match[0][0]
|
||||||
);
|
);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -210,9 +213,11 @@ class JedcheckerRulesGpl extends JEDcheckerRule
|
|||||||
$line_no = substr_count($content, "\n", 0, $match[0][1]) + 1;
|
$line_no = substr_count($content, "\n", 0, $match[0][1]) + 1;
|
||||||
$this->report->addInfo(
|
$this->report->addInfo(
|
||||||
$file,
|
$file,
|
||||||
JText::_('COM_JEDCHECKER_GPL_COMPATIBLE_LICENSE_WAS_FOUND') . ':' . '<strong>' . $match[0][0] . '</strong>',
|
JText::_('COM_JEDCHECKER_GPL_COMPATIBLE_LICENSE_WAS_FOUND'),
|
||||||
$line_no
|
$line_no,
|
||||||
|
$match[0][0]
|
||||||
);
|
);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user