1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-27 01:02:42 +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:
vrana 2013-02-10 06:41:19 -08:00
parent a22ef4e9b4
commit c3ae8286db

View file

@ -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) {