Added new factory and fixed confusing between login and actual user classes.
[core.git] / inc / classes / main / actions / post_registration / class_LoginAfterRegistrationAction.php
index e1e672c6b8dee53074f525267c4d71874d532333..2ee908448ca839ba56647ca26f50f5b98548afe3 100644 (file)
@@ -2,11 +2,11 @@
 /**
  * A post registration action to login after the registration is done
  *
- * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @author             Roland Haeder <webmaster@shipsimu.org>
  * @version            0.0.0
- * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2011 Core Developer Team
+ * @copyright  Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2015 Core Developer Team
  * @license            GNU GPL 3.0 or any newer version
- * @link               http://www.ship-simu.org
+ * @link               http://www.shipsimu.org
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -54,7 +54,7 @@ class LoginAfterRegistrationAction extends BaseAction implements PerformableActi
         */
        public function execute (Requestable $requestInstance, Responseable $responseInstance) {
                // Get a login class from factory
-               $loginInstance = ObjectFactory::createObjectByConfiguredName('user_login_class');
+               $loginInstance = LoginFactory::createLoginObjectByRequest($requestInstance);
 
                // Login the user by the request instance
                $loginInstance->doLogin($requestInstance, $responseInstance);