This is an automated email from the ASF dual-hosted git repository.
sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-net.git
The following commit(s) were added to refs/heads/master by this push:
new 7f19ea7 Simplify
7f19ea7 is described below
commit 7f19ea792908c25ce46fcf9f841a2def1eb9eaec
Author: Sebb <[email protected]>
AuthorDate: Tue Jun 23 00:11:53 2020 +0100
Simplify
---
src/main/java/org/apache/commons/net/smtp/SMTP.java | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/src/main/java/org/apache/commons/net/smtp/SMTP.java
b/src/main/java/org/apache/commons/net/smtp/SMTP.java
index c09dca4..809fa67 100644
--- a/src/main/java/org/apache/commons/net/smtp/SMTP.java
+++ b/src/main/java/org/apache/commons/net/smtp/SMTP.java
@@ -129,7 +129,7 @@ public class SMTP extends SocketClient
*/
public SMTP(String encoding) {
setDefaultPort(DEFAULT_PORT);
- _replyLines = new ArrayList<String>();
+ _replyLines = new ArrayList<>();
_newReplyString = false;
_replyString = null;
_commandSupport_ = new ProtocolCommandSupport(this);
@@ -161,8 +161,8 @@ public class SMTP extends SocketClient
__commandBuffer.append(SocketClient.NETASCII_EOL);
- String message;
- _writer.write(message = __commandBuffer.toString());
+ String message = __commandBuffer.toString();
+ _writer.write(message);
_writer.flush();
fireCommandSent(command, message);
@@ -465,7 +465,8 @@ public class SMTP extends SocketClient
_newReplyString = false;
- return (_replyString = buffer.toString());
+ _replyString = buffer.toString();
+ return (_replyString);
}