Cleanup regex methods