Failed Conditions
Push — 3.0.9-dev ( 720aa2...3dd81f )
by k-yamamura
60:00 queued 32:44
created
src/Eccube/Event/FormEventSubscriber.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,6 @@
 block discarded – undo
29 29
 use Symfony\Component\EventDispatcher\EventSubscriberInterface;
30 30
 use Symfony\Component\Finder\Finder;
31 31
 use Symfony\Component\Yaml\Yaml;
32
-use Monolog\Logger;
33 32
 
34 33
 class FormEventSubscriber implements EventSubscriberInterface
35 34
 {
Please login to merge, or discard this patch.
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     {
38 38
         $events = array();
39 39
         // YamlでParseしてがんばる
40
-        $basePath = __DIR__ . '/../../../app/Plugin';
40
+        $basePath = __DIR__.'/../../../app/Plugin';
41 41
         $finder = Finder::create()
42 42
             ->in($basePath)
43 43
             ->directories()
@@ -46,18 +46,18 @@  discard block
 block discarded – undo
46 46
         $app = \Eccube\Application::getInstance();
47 47
 
48 48
         foreach ($finder as $dir) {
49
-            $config = Yaml::parse(file_get_contents($dir->getRealPath() . '/config.yml'));
49
+            $config = Yaml::parse(file_get_contents($dir->getRealPath().'/config.yml'));
50 50
             try {
51 51
                 $app['eccube.service.plugin']->checkPluginArchiveContent($dir->getRealPath());
52
-            } catch(\Eccube\Exception\PluginException $e) {
52
+            } catch (\Eccube\Exception\PluginException $e) {
53 53
                 $app['monolog']->warning($e->getMessage());
54 54
                 continue;
55 55
             }
56
-            $config = $app['eccube.service.plugin']->readYml($dir->getRealPath() . '/config.yml');
56
+            $config = $app['eccube.service.plugin']->readYml($dir->getRealPath().'/config.yml');
57 57
 
58 58
             if (isset($config['form'])) {
59 59
                 foreach ($config['form'] as $event => $class) {
60
-                    $events[$event][] = '\\Plugin\\' . $config['code'] . '\\' . $class;
60
+                    $events[$event][] = '\\Plugin\\'.$config['code'].'\\'.$class;
61 61
                 }
62 62
             }
63 63
         }
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
         $events = self::getEvents();
82 82
 
83 83
         if (isset($events['onPreSetData'])) {
84
-            foreach($events['onPreSetData'] as $formEventClass) {
84
+            foreach ($events['onPreSetData'] as $formEventClass) {
85 85
                 $formEvent = new $formEventClass();
86 86
                 $formEvent->onPreSetData($event);
87 87
             }
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         $events = self::getEvents();
94 94
 
95 95
         if (isset($events['onPostSetData'])) {
96
-            foreach($events['onPostSetData'] as $formEventClass) {
96
+            foreach ($events['onPostSetData'] as $formEventClass) {
97 97
                 $formEvent = new $formEventClass();
98 98
                 $formEvent->onPostSetData($event);
99 99
             }
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
         $events = self::getEvents();
106 106
 
107 107
         if (isset($events['onPreSubmit'])) {
108
-            foreach($events['onPreSubmit'] as $formEventClass) {
108
+            foreach ($events['onPreSubmit'] as $formEventClass) {
109 109
                 $formEvent = new $formEventClass();
110 110
                 $formEvent->onPreSubmit($event);
111 111
             }
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
         $events = self::getEvents();
118 118
 
119 119
         if (isset($events['onSubmit'])) {
120
-            foreach($events['onSubmit'] as $formEventClass) {
120
+            foreach ($events['onSubmit'] as $formEventClass) {
121 121
                 $formEvent = new $formEventClass();
122 122
                 $formEvent->onSubmit($event);
123 123
             }
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
         $events = self::getEvents();
130 130
 
131 131
         if (isset($events['onPostSubmit'])) {
132
-            foreach($events['onPostSubmit'] as $formEventClass) {
132
+            foreach ($events['onPostSubmit'] as $formEventClass) {
133 133
                 $formEvent = new $formEventClass();
134 134
                 $formEvent->onPostSubmit($event);
135 135
             }
Please login to merge, or discard this patch.
src/Eccube/Controller/ProductController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@
 block discarded – undo
106 106
             ));
107 107
             $addCartForm = $builder->getForm();
108 108
 
109
-            if ($request->getMethod() === 'POST' && (string)$Product->getId() === $request->get('product_id')) {
109
+            if ($request->getMethod() === 'POST' && (string) $Product->getId() === $request->get('product_id')) {
110 110
                 $addCartForm->handleRequest($request);
111 111
 
112 112
                 if ($addCartForm->isValid()) {
Please login to merge, or discard this patch.