added trim to mongo component injection