public static void RegisterServices(IKernel kernel)
        {
            var passwordHelper = new PasswordHelper();
            passwordHelper.Initialize();

            var repository = new Repository(
                new ProductionSessionFactoryContainer(
                    ConfigurationManager.ConnectionStrings["PeerLearn"].
                        ConnectionString).CreateSessionFactory());

            kernel.Bind<IRepository>().ToConstant(repository);
            kernel.Bind<IEventService>().To<EventService>();
            kernel.Bind<IFormsAuthenticationService>().To<FormsAuthenticationService>();
            kernel.Bind<PasswordHelper>().ToConstant(passwordHelper);
        }
 public AccountController(IRepository repository, PasswordHelper crypto, IFormsAuthenticationService authService)
 {
     _repository = repository;
     _passwordCrypto = crypto;
     _authentication = authService;
 }