Fixed the comma,factory call and return statement