Fixed fetch_updates function