mirror of
https://github.com/google/nomulus
synced 2026-09-19 22:44:26 +00:00
Add user objects for local test server (#2744)
Also don't try to do anything related to Google admin directory objects when running the local test server, for obvious reasons
This commit is contained in:
@@ -144,7 +144,6 @@ public abstract class CredentialModule {
|
||||
Duration tokenRefreshDelay,
|
||||
Clock clock) {
|
||||
GoogleCredentials signer = credentialsBundle.getGoogleCredentials();
|
||||
|
||||
checkArgument(
|
||||
signer instanceof ServiceAccountSigner,
|
||||
"Expecting a ServiceAccountSigner, found %s.",
|
||||
|
||||
@@ -165,7 +165,7 @@ public class ConsoleUsersAction extends ConsoleApiAction {
|
||||
User updatedUser = updateUserRegistrarRoles(email, registrarId, null);
|
||||
|
||||
// User has no registrars assigned
|
||||
if (updatedUser.getUserRoles().getRegistrarRoles().size() == 0) {
|
||||
if (updatedUser.getUserRoles().getRegistrarRoles().isEmpty()) {
|
||||
try {
|
||||
directory.users().delete(email).execute();
|
||||
} catch (IOException e) {
|
||||
|
||||
Reference in New Issue
Block a user