From: Joshua Spence Date: Sun, 4 Jan 2015 20:43:55 +0000 (+1100) Subject: Various improvements for `ArcanistClosureLinter` X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=eb3129408bbafa4608b42b2405d614f79632cb1d;p=arcanist.git Various improvements for `ArcanistClosureLinter` Summary: WIP Test Plan: WIP Reviewers: #blessed_reviewers, epriestley Reviewed By: #blessed_reviewers, epriestley Subscribers: epriestley Differential Revision: https://secure.phabricator.com/D11207 --- diff --git a/src/lint/linter/ArcanistClosureLinter.php b/src/lint/linter/ArcanistClosureLinter.php index 89097382..d437f3b6 100644 --- a/src/lint/linter/ArcanistClosureLinter.php +++ b/src/lint/linter/ArcanistClosureLinter.php @@ -1,7 +1,7 @@ $match) { - $matches[$key] = trim($match); - } - - $message = new ArcanistLintMessage(); - $message->setPath($path); - $message->setLine($matches[1]); - $message->setName($matches[2]); - $message->setCode($this->getLinterName()); - $message->setDescription($matches[3]); - $message->setSeverity($severity_code); + $message = id(new ArcanistLintMessage()) + ->setPath($path) + ->setLine($matches[1]) + ->setSeverity(ArcanistLintSeverity::SEVERITY_ERROR) + ->setCode($this->getLinterName().$matches[2]) + ->setDescription($matches[3]); $messages[] = $message; }