]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-3755 Use RubyUtils to parse deadline when creating action plan
authorJulien Lancelot <julien.lancelot@gmail.com>
Fri, 7 Jun 2013 12:32:22 +0000 (14:32 +0200)
committerJulien Lancelot <julien.lancelot@gmail.com>
Fri, 7 Jun 2013 12:32:22 +0000 (14:32 +0200)
sonar-server/src/main/java/org/sonar/server/issue/InternalRubyIssueService.java

index 87533a774abb14fee5153ad40aed776da3571d16..abdebc9293c3a564b576d69e869fb95ec14aa60d 100644 (file)
@@ -31,7 +31,6 @@ import org.sonar.api.issue.action.Action;
 import org.sonar.api.issue.internal.DefaultIssue;
 import org.sonar.api.rule.RuleKey;
 import org.sonar.api.rule.Severity;
-import org.sonar.api.utils.DateUtils;
 import org.sonar.api.utils.SonarException;
 import org.sonar.core.issue.ActionPlanStats;
 import org.sonar.core.issue.DefaultActionPlan;
@@ -305,7 +304,7 @@ public class InternalRubyIssueService implements ServerComponent {
 
     if (!Strings.isNullOrEmpty(deadLineParam)) {
       try {
-        deadLine = DateUtils.parseDate(deadLineParam);
+        deadLine = RubyUtils.toDate(deadLineParam);
         Date today = new Date();
         if (deadLine.before(today) && !org.apache.commons.lang.time.DateUtils.isSameDay(deadLine, today)) {
           result.addError(Result.Message.ofL10n("action_plans.date_cant_be_in_past"));