]> git.mxchange.org Git - city.git/blobdiff - application/city/classes/commands/html/class_CityHtmlResendLinkCommand.php
Continued:
[city.git] / application / city / classes / commands / html / class_CityHtmlResendLinkCommand.php
index 174459448adb05ef6e1c5e1f136c3a905a923848..b217ff506fa2efb0590601cb21d1e7c96956cee4 100644 (file)
@@ -1,10 +1,23 @@
 <?php
+// Own namespace
+namespace Org\Mxchange\City\Command;
+
+// Import framework stuff
+use Org\Mxchange\CoreFramework\Command\BaseCommand;
+use Org\Mxchange\CoreFramework\Command\Commandable;
+use Org\Mxchange\CoreFramework\Controller\Controller;
+use Org\Mxchange\CoreFramework\Factory\ObjectFactory;
+use Org\Mxchange\CoreFramework\Registry\GenericRegistry;
+use Org\Mxchange\CoreFramework\Request\Requestable;
+use Org\Mxchange\CoreFramework\Resolver\Command\CommandResolver;
+use Org\Mxchange\CoreFramework\Response\Responseable;
+
 /**
  * A command class for resending the confirmation link
  *
  * @author             Roland Haeder <webmaster@shipsimu.org>
  * @version            0.0.0
- * @copyright  Copyright (c) 2015 City Developer Team
+ * @copyright  Copyright (c) 2015, 2016 City Developer Team
  * @license            GNU GPL 3.0 or any newer version
  * @link               http://www.shipsimu.org
  *
@@ -58,10 +71,10 @@ class CityHtmlResendLinkCommand extends BaseCommand implements Commandable {
         */
        public function execute (Requestable $requestInstance, Responseable $responseInstance) {
                // Get user instance from registry
-               $userInstance = Registry::getRegistry()->getInstance('user');
+               $userInstance = GenericRegistry::getRegistry()->getInstance('user');
 
                // Get an application instance
-               $applicationInstance = $this->getResolverInstance()->getApplicationInstance();
+               $applicationInstance = GenericRegistry::getRegistry()->getInstance('application');
 
                // Get a RNG instance (Random Number Generator)
                $rngInstance = ObjectFactory::createObjectByConfiguredName('rng_class');
@@ -85,10 +98,10 @@ class CityHtmlResendLinkCommand extends BaseCommand implements Commandable {
                $templateInstance = $this->prepareTemplateInstance($applicationInstance);
 
                // Assign the application data with the template engine
-               $templateInstance->assignApplicationData($applicationInstance);
+               $templateInstance->assignApplicationData();
 
                // Get a mailer class
-               $mailerInstance = ObjectFactory::createObjectByConfiguredName('mailer_class', array($templateInstance, $applicationInstance, 'resend_link'));
+               $mailerInstance = ObjectFactory::createObjectByConfiguredName('mailer_class', array($templateInstance, 'resend_link'));
 
                // Set this mailer in our template engine
                $templateInstance->setMailerInstance($mailerInstance);
@@ -130,6 +143,3 @@ class CityHtmlResendLinkCommand extends BaseCommand implements Commandable {
                $controllerInstance->addPreFilter(ObjectFactory::createObjectByConfiguredName('user_unconfirmed_filter'));
        }
 }
-
-// [EOF]
-?>