Potential fix for race condition.