for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Webino (http://webino.sk)
*
* @link https://github.com/webino/WebinoCanonicalRedirect for the canonical source repository
* @copyright Copyright (c) 2014-2017 Webino, s. r. o. (http://webino.sk)
* @author Peter Bačinský <[email protected]>
* @license BSD-3-Clause
*/
namespace WebinoCanonicalRedirect\Factory;
use WebinoCanonicalRedirect\Options\ModuleOptions;
use Zend\ServiceManager\FactoryInterface;
use Zend\ServiceManager\ServiceLocatorInterface;
* Factory for the module options
class ModuleOptionsFactory implements FactoryInterface
{
* @param ServiceLocatorInterface $services
* @return ModuleOptions
public function createService(ServiceLocatorInterface $services)
$config = $services->get('Config');
return new ModuleOptions(
!empty($config['webino_canonical_redirect'])
? $config['webino_canonical_redirect']
: array()
);
}