Skip to content

Commit

Permalink
Make SimpleMailMessage setter parameters nullable
Browse files Browse the repository at this point in the history
  • Loading branch information
stgerhardt authored and sdeleuze committed Nov 2, 2022
1 parent c14cbd0 commit bf70a90
Showing 1 changed file with 10 additions and 10 deletions.
Expand Up @@ -93,7 +93,7 @@ public SimpleMailMessage(SimpleMailMessage original) {


@Override
public void setFrom(String from) {
public void setFrom(@Nullable String from) {
this.from = from;
}

Expand All @@ -103,7 +103,7 @@ public String getFrom() {
}

@Override
public void setReplyTo(String replyTo) {
public void setReplyTo(@Nullable String replyTo) {
this.replyTo = replyTo;
}

Expand All @@ -113,7 +113,7 @@ public String getReplyTo() {
}

@Override
public void setTo(String to) {
public void setTo(@Nullable String to) {
this.to = new String[] {to};
}

Expand All @@ -128,12 +128,12 @@ public String[] getTo() {
}

@Override
public void setCc(String cc) {
public void setCc(@Nullable String cc) {
this.cc = new String[] {cc};
}

@Override
public void setCc(String... cc) {
public void setCc(@Nullable String... cc) {
this.cc = cc;
}

Expand All @@ -143,12 +143,12 @@ public String[] getCc() {
}

@Override
public void setBcc(String bcc) {
public void setBcc(@Nullable String bcc) {
this.bcc = new String[] {bcc};
}

@Override
public void setBcc(String... bcc) {
public void setBcc(@Nullable String... bcc) {
this.bcc = bcc;
}

Expand All @@ -158,7 +158,7 @@ public String[] getBcc() {
}

@Override
public void setSentDate(Date sentDate) {
public void setSentDate(@Nullable Date sentDate) {
this.sentDate = sentDate;
}

Expand All @@ -168,7 +168,7 @@ public Date getSentDate() {
}

@Override
public void setSubject(String subject) {
public void setSubject(@Nullable String subject) {
this.subject = subject;
}

Expand All @@ -178,7 +178,7 @@ public String getSubject() {
}

@Override
public void setText(String text) {
public void setText(@Nullable String text) {
this.text = text;
}

Expand Down

0 comments on commit bf70a90

Please sign in to comment.