Fix CASA::App:Engine constructor bug and add Content-type validation