@@ -51,7 +51,6 @@ public KeystoneAuth(String userId, String password) {
5151 public KeystoneAuth (String user , String password , Identifier domain , AuthScope scope ) {
5252 this .identity = AuthIdentity .createCredentialType (user , password , domain );
5353 this .scope = scope ;
54- this .type = Type .CREDENTIALS ;
5554 }
5655
5756 public KeystoneAuth (AuthScope scope , Type type ) {
@@ -200,13 +199,15 @@ public AuthUser(String username, String password, Identifier domainIdentifier) {
200199 this .password = password ;
201200 if (domainIdentifier != null ) {
202201 domain = new AuthDomain ();
203- if (domainIdentifier .isTypeID ())
204- domain .setId (domainIdentifier .getId ());
205- else
206- domain .setName (domainIdentifier .getId ());
202+ if (domainIdentifier .isTypeID ()) {
203+ domain .setId (domainIdentifier .getId ());
204+ } else {
205+ domain .setName (domainIdentifier .getId ());
206+ }
207207 setName (username );
208- } else
209- setId (username );
208+ } else {
209+ setId (username );
210+ }
210211 }
211212
212213 @ Override
@@ -342,10 +343,11 @@ public static final class AuthDomain extends BasicResourceEntity implements Doma
342343 private String name ;
343344
344345 public AuthDomain (Identifier domain ) {
345- if (domain .isTypeID ())
346- this .id = domain .getId ();
347- else
348- this .name = domain .getId ();
346+ if (domain .isTypeID ()) {
347+ this .id = domain .getId ();
348+ } else {
349+ this .name = domain .getId ();
350+ }
349351 }
350352
351353 @ Override
0 commit comments