cleaned up controller codes. removed many console logs for code review.