refine getting mid