mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-07 01:54:22 +00:00
[DS-1530] Insist on a nonblank email address
This commit is contained in:
@@ -45,7 +45,7 @@ import org.dspace.eperson.Group;
|
||||
public final class CreateAdministrator
|
||||
{
|
||||
/** DSpace Context object */
|
||||
private Context context;
|
||||
private final Context context;
|
||||
|
||||
/**
|
||||
* For invoking via the command line. If called with no command line arguments,
|
||||
@@ -123,10 +123,15 @@ public final class CreateAdministrator
|
||||
System.out.flush();
|
||||
|
||||
email = input.readLine();
|
||||
if (email != null)
|
||||
if (!StringUtils.isBlank(email))
|
||||
{
|
||||
email = email.trim();
|
||||
}
|
||||
else
|
||||
{
|
||||
System.out.println("Please provide an email address.");
|
||||
continue;
|
||||
}
|
||||
|
||||
System.out.print("First name: ");
|
||||
System.out.flush();
|
||||
|
Reference in New Issue
Block a user