fix the removeHead regexp