remove commented code, ensure platform.js loaded first