regex improvement for frover script