Completed
Pull Request — develop (#455)
by ANTHONIUS
24:00
created
module/Core/Module.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
     public function getConsoleBanner(Console $console)
42 42
     {
43 43
         $version = `git describe 2>/dev/null`;
44
-        $name = 'YAWIK ' . trim($version);
44
+        $name = 'YAWIK '.trim($version);
45 45
         $width = $console->getWidth();
46 46
         return sprintf(
47 47
             "==%1\$s==\n%2\$s%3\$s\n**%1\$s**\n",
@@ -111,8 +111,8 @@  discard block
 block discarded – undo
111 111
 
112 112
         $eventManager->attach(
113 113
             MvcEvent::EVENT_DISPATCH_ERROR,
114
-            function ($event) {
115
-            	if($event instanceof MvcEvent){
114
+            function($event) {
115
+            	if ($event instanceof MvcEvent) {
116 116
 		            $application = $event->getApplication();
117 117
 		            
118 118
 		            if ($application::ERROR_EXCEPTION == $event->getError()) {
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
         );
128 128
         $eventManager->attach(
129 129
             MvcEvent::EVENT_DISPATCH,
130
-            function ($event) use ($eventManager) {
130
+            function($event) use ($eventManager) {
131 131
                 $eventManager->trigger('postDispatch', $event);
132 132
             },
133 133
             -150
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
      */
143 143
     public function getConfig()
144 144
     {
145
-        $config = include __DIR__ . '/config/module.config.php';
145
+        $config = include __DIR__.'/config/module.config.php';
146 146
         return $config;
147 147
     }
148 148
 
@@ -155,13 +155,13 @@  discard block
 block discarded – undo
155 155
     {
156 156
         return array(
157 157
             'Zend\Loader\ClassMapAutoloader' => [
158
-                __DIR__ . '/src/autoload_classmap.php'
158
+                __DIR__.'/src/autoload_classmap.php'
159 159
             ],
160 160
             'Zend\Loader\StandardAutoloader' => array(
161 161
                 'namespaces' => array(
162
-                    __NAMESPACE__ => __DIR__ . '/src/' . __NAMESPACE__,
163
-                    'CoreTest' => __DIR__ . '/test/' . 'CoreTest',
164
-                    'CoreTestUtils' => __DIR__ . '/test/CoreTestUtils',
162
+                    __NAMESPACE__ => __DIR__.'/src/'.__NAMESPACE__,
163
+                    'CoreTest' => __DIR__.'/test/'.'CoreTest',
164
+                    'CoreTestUtils' => __DIR__.'/test/CoreTestUtils',
165 165
                 ),
166 166
             ),
167 167
         );
Please login to merge, or discard this patch.
module/Core/src/Core/Repository/AbstractRepository.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -122,11 +122,11 @@  discard block
 block discarded – undo
122 122
         return $this;
123 123
     }
124 124
 
125
-    public function remove($entity,$flush=false)
125
+    public function remove($entity, $flush = false)
126 126
     {
127 127
         $this->checkEntityType($entity);
128 128
         $this->dm->remove($entity);
129
-		if($flush){
129
+		if ($flush) {
130 130
 			$this->dm->flush($entity);
131 131
 		}
132 132
         return $this;
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
 
135 135
     protected function checkEntityType($entity)
136 136
     {
137
-        if ( !($entity instanceOf $this->entityPrototype) ) {
137
+        if (!($entity instanceOf $this->entityPrototype)) {
138 138
             throw new \InvalidArgumentException(sprintf(
139 139
                                                     'Entity must be of type %s but recieved %s instead',
140 140
                                                     get_class($this->entityPrototype),
Please login to merge, or discard this patch.
module/Core/src/Core/Repository/DoctrineMongoODM/DocumentManagerFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@
 block discarded – undo
22 22
  */
23 23
 class DocumentManagerFactory implements FactoryInterface
24 24
 {
25
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null ) {
25
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null) {
26 26
 		$container->setAllowOverride(true);
27 27
 		$container->setFactory('doctrine.configuration.odm_default', new ConfigurationFactory('odm_default'));
28 28
 		$container->setAllowOverride(false);
Please login to merge, or discard this patch.
module/Core/src/Core/Repository/RepositoryServiceFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
 class RepositoryServiceFactory implements FactoryInterface
22 22
 {
23 23
 	
24
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null ) {
24
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null) {
25 25
 		$dm      = $container->get('Core/DocumentManager');
26 26
 		$service = new RepositoryService($dm);
27 27
 		
Please login to merge, or discard this patch.
module/Core/src/Core/Filter/XssFilterFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 	 *
30 30
 	 * @return XssFilter
31 31
 	 */
32
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
32
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
33 33
 	{
34 34
 		$htmlPurifier = new Filter\HTMLPurifierFilter();
35 35
 		$htmlPurifier->setConfig(array("Cache.SerializerPath" => "cache/HtmlPurifier"));
Please login to merge, or discard this patch.
module/Core/src/Core/Entity/Tree/AbstractLeafs.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 {
29 29
     use EntityTrait, ClonePropertiesTrait;
30 30
 
31
-    private $cloneProperties = [ '!items' ];
31
+    private $cloneProperties = ['!items'];
32 32
 
33 33
     /**
34 34
      * The leafs.
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
         $values = [];
87 87
         /* @var NodeInterface $item */
88 88
         foreach ($this->getItems() as $item) {
89
-        	if(!is_null($item)){
89
+        	if (!is_null($item)) {
90 90
 		        $values[] = $item->getValueWithParents();
91 91
 	        }
92 92
         }
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
                 $parent = $nextParent;
116 116
             }
117 117
             $nameParts[] = $item->getName();
118
-            $items[]     = join(' | ' , $nameParts);
118
+            $items[]     = join(' | ', $nameParts);
119 119
 
120 120
         }
121 121
 
Please login to merge, or discard this patch.
module/Core/src/Core/Entity/Hydrator/EntityHydratorFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
 {
22 22
     protected $hydrator;
23 23
 	
24
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
24
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
25 25
 	{
26 26
 		$this->hydrator = $this->getEntityHydrator();
27 27
 		$this->prepareHydrator();
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
      */
38 38
     public function createService(ServiceLocatorInterface $serviceLocator)
39 39
     {
40
-		return $this($serviceLocator,EntityHydrator::class);
40
+		return $this($serviceLocator, EntityHydrator::class);
41 41
     }
42 42
 
43 43
     protected function prepareHydrator()
Please login to merge, or discard this patch.
module/Core/src/Core/Entity/Hydrator/JsonEntityHydratorFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
 {
22 22
     protected $hydrator;
23 23
 	
24
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
24
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
25 25
 	{
26 26
 		$this->hydrator = new JsonEntityHydrator();
27 27
 		$entityHydrator = $this->getEntityHydrator();
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      */
40 40
     public function createService(ServiceLocatorInterface $serviceLocator)
41 41
     {
42
-        return $this($serviceLocator,JsonEntityHydrator::class);
42
+        return $this($serviceLocator, JsonEntityHydrator::class);
43 43
     }
44 44
 
45 45
     protected function prepareHydrator() {
Please login to merge, or discard this patch.
module/Core/src/Core/View/Helper/Service/ParamsHelperFactory.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
  */
26 26
 class ParamsHelperFactory implements FactoryInterface
27 27
 {
28
-	public function __invoke( ContainerInterface $container, $requestedName, array $options = null )
28
+	public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
29 29
 	{
30 30
 		$event = $container->get('Application')->getMvcEvent();
31 31
 		$helper = new Params($event);
@@ -43,6 +43,6 @@  discard block
 block discarded – undo
43 43
      */
44 44
     public function createService(ServiceLocatorInterface $serviceLocator)
45 45
     {
46
-		return $this($serviceLocator,Params::class);
46
+		return $this($serviceLocator, Params::class);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.