Fix crash for app.js and commands.js.