Added regex functionality