You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by ro...@apache.org on 2019/10/23 09:02:54 UTC
[james-project] 02/02: JAMES-2928 WithPriority's checkstyle fixes
This is an automated email from the ASF dual-hosted git repository.
rouazana pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git
commit b26313c471034be571b9e2c66e381a4f1f52688c
Author: Gautier DI FOLCO <gd...@linagora.com>
AuthorDate: Tue Oct 22 11:40:33 2019 +0200
JAMES-2928 WithPriority's checkstyle fixes
---
.../org/apache/james/transport/mailets/WithPriority.java | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/server/mailet/mailets/src/main/java/org/apache/james/transport/mailets/WithPriority.java b/server/mailet/mailets/src/main/java/org/apache/james/transport/mailets/WithPriority.java
index 3fc9776..3138f4b 100644
--- a/server/mailet/mailets/src/main/java/org/apache/james/transport/mailets/WithPriority.java
+++ b/server/mailet/mailets/src/main/java/org/apache/james/transport/mailets/WithPriority.java
@@ -50,17 +50,17 @@ public class WithPriority extends GenericMailet {
@Override
public void init() throws MessagingException {
Integer priorityRaw = Optional.ofNullable(getInitParameter("priority", null))
- .map(Integer::valueOf)
- .orElseThrow(() -> new IllegalArgumentException("'priority' init parameter is compulsory"));
+ .map(Integer::valueOf)
+ .orElseThrow(() -> new IllegalArgumentException("'priority' init parameter is compulsory"));
if (priorityRaw < 0 || priorityRaw > 9) {
throw new IllegalArgumentException("Invalid priority: Priority should be from 0 to 9");
- }
- priority = new Attribute(MailPrioritySupport.MAIL_PRIORITY, AttributeValue.of(priorityRaw));
}
+ priority = new Attribute(MailPrioritySupport.MAIL_PRIORITY, AttributeValue.of(priorityRaw));
+ }
- @Override
- public void service(Mail mail) throws MessagingException {
- mail.setAttribute(priority);
- }
+ @Override
+ public void service(Mail mail) throws MessagingException {
+ mail.setAttribute(priority);
}
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org