mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-28 00:10:57 +01:00
Configure PhutilXHPAST linter
Test Plan: $ arc lint src/applications/audit/controller/PhabricatorAuditListController.php Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Maniphest Tasks: T2432 Differential Revision: https://secure.phabricator.com/D4895
This commit is contained in:
parent
a22ef4e9b4
commit
c3ae8286db
1 changed files with 18 additions and 0 deletions
|
@ -5,6 +5,24 @@ final class PhabricatorLintEngine extends PhutilLintEngine {
|
|||
public function buildLinters() {
|
||||
$linters = parent::buildLinters();
|
||||
|
||||
foreach ($linters as $linter) {
|
||||
if ($linter instanceof ArcanistPhutilXHPASTLinter) {
|
||||
$linter->setDeprecatedFunctions(array(
|
||||
'phutil_escape_html' =>
|
||||
'The phutil_escape_html() function is deprecated. Raw strings '.
|
||||
'passed to phutil_tag() or hsprintf() are escaped automatically.',
|
||||
|
||||
'javelin_render_tag' =>
|
||||
'The javelin_render_tag() function is deprecated and unsafe. '.
|
||||
'Use javelin_tag() instead.',
|
||||
|
||||
'phabricator_render_form' =>
|
||||
'The phabricator_render_form() function is deprecated and unsafe. '.
|
||||
'Use phabricator_form() instead.',
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
$paths = $this->getPaths();
|
||||
|
||||
foreach ($paths as $key => $path) {
|
||||
|
|
Loading…
Reference in a new issue