It doesn't look like you use this code in camera.js, do you? Can't you remove this line?