Revision dd27bc21

b/lib/utils/algo.py
32 32

  
33 33
_SORTER_GROUPS = 8
34 34
_SORTER_RE = re.compile("^%s(.*)$" % (_SORTER_GROUPS * "(\D+|\d+)?"))
35
_SORTER_DIGIT = re.compile("^\d+$")
36 35

  
37 36

  
38 37
def UniqueSequence(seq):
......
100 99
  """Attempts to convert a string to an integer.
101 100

  
102 101
  """
103
  if val and _SORTER_DIGIT.match(val):
102
  if val and val.isdigit():
104 103
    return int(val)
105 104
  else:
106 105
    return val

Also available in: Unified diff