implementing when_fresh for staleElementReferenceError