mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-07 18:14:26 +00:00
Email addresses need at-symbol to be a word character when tokenizing
This commit is contained in:
@@ -60,13 +60,19 @@ public class CommandRunner
|
|||||||
StreamTokenizer tokenizer = new StreamTokenizer(input);
|
StreamTokenizer tokenizer = new StreamTokenizer(input);
|
||||||
|
|
||||||
tokenizer.eolIsSignificant(true);
|
tokenizer.eolIsSignificant(true);
|
||||||
|
|
||||||
tokenizer.ordinaryChar('-');
|
tokenizer.ordinaryChar('-');
|
||||||
tokenizer.wordChars('-', '-');
|
tokenizer.wordChars('-', '-');
|
||||||
|
|
||||||
tokenizer.ordinaryChars('0', '9');
|
tokenizer.ordinaryChars('0', '9');
|
||||||
tokenizer.wordChars('0', '9');
|
tokenizer.wordChars('0', '9');
|
||||||
|
|
||||||
tokenizer.ordinaryChar('.');
|
tokenizer.ordinaryChar('.');
|
||||||
tokenizer.wordChars('.', '.');
|
tokenizer.wordChars('.', '.');
|
||||||
|
|
||||||
|
tokenizer.ordinaryChar('@');
|
||||||
|
tokenizer.wordChars('@', '@');
|
||||||
|
|
||||||
int status = 0;
|
int status = 0;
|
||||||
List<String> tokens = new ArrayList<String>();
|
List<String> tokens = new ArrayList<String>();
|
||||||
while (StreamTokenizer.TT_EOF != tokenizer.nextToken())
|
while (StreamTokenizer.TT_EOF != tokenizer.nextToken())
|
||||||
|
Reference in New Issue
Block a user