Updated ref regex