mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-18 02:02:04 +01:00
sinttest: Throw exception if service is not set
This commit is contained in:
parent
60b07b1d67
commit
4c18814b12
1 changed files with 5 additions and 0 deletions
|
@ -122,6 +122,11 @@ public final class Configuration {
|
|||
}
|
||||
|
||||
public Builder setService(String service) throws XmppStringprepException {
|
||||
if (service == null) {
|
||||
// Do nothing if user did not specify the XMPP service domain. When the builder
|
||||
// builds a configuration using build() it will throw a meaningful exception.
|
||||
return this;
|
||||
}
|
||||
return setService(JidCreate.domainBareFrom(service));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue