Removed API controller; Control flow optimization, etc.