silly regex
This commit is contained in:
parent
28ca47394b
commit
3a76e62ba9
1 changed files with 1 additions and 1 deletions
|
@ -7,7 +7,7 @@ import java.util.regex.Matcher;
|
|||
import java.util.regex.Pattern;
|
||||
|
||||
public class DurationUtils {
|
||||
private static final Pattern timePattern = Pattern.compile("(\\d+)(?:([dhms]))?");
|
||||
private static final Pattern timePattern = Pattern.compile("(\\d+)([dhms])?");
|
||||
public static Duration parseDuration(String input) throws IllegalArgumentException {
|
||||
Matcher matcher = timePattern.matcher(input);
|
||||
|
||||
|
|
Loading…
Reference in a new issue