Update phaseManager.js