@@ -39,7 +39,7 @@ |
||
39 | 39 | if($cold){ |
40 | 40 | $type = 'cold'; |
41 | 41 | $count = $this->coldDrinkCounter; |
42 | - }else{ |
|
42 | + } else{ |
|
43 | 43 | $type = 'hot'; |
44 | 44 | $count = $this->hotDrinkCounter; |
45 | 45 | } |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | |
120 | 120 | if($this->hasService($key)){ |
121 | 121 | $service = $this->getService($key); |
122 | - }else{ |
|
122 | + } else{ |
|
123 | 123 | $service = $this->createService($key); |
124 | 124 | } |
125 | 125 | |
@@ -151,11 +151,11 @@ discard block |
||
151 | 151 | )); |
152 | 152 | |
153 | 153 | return $node; |
154 | - }else{ |
|
154 | + } else{ |
|
155 | 155 | $errorMessage = 'COULD NOT BUILD NODE FOR KEY: '.$key; |
156 | 156 | } |
157 | 157 | |
158 | - }else{ |
|
158 | + } else{ |
|
159 | 159 | $errorMessage = 'NO CONFIG FOR KEY: '.$key; |
160 | 160 | } |
161 | 161 | $this->doFireEvent(self::EVENT_CREATE_SERVICE_ERROR, array( |
@@ -199,10 +199,10 @@ discard block |
||
199 | 199 | self::HEADER_NODE => $nodeInstance |
200 | 200 | )); |
201 | 201 | return $nodeInstance; |
202 | - }else{ |
|
202 | + } else{ |
|
203 | 203 | $errorMessage = 'BUILDER RETURNED NO OBJECT FOR NODE-TYPE: '.$nodeName; |
204 | 204 | } |
205 | - }else{ |
|
205 | + } else{ |
|
206 | 206 | $errorMessage = 'NO BUILDER FOUND FOR NODE-TYPE: '.$nodeName; |
207 | 207 | } |
208 | 208 |
@@ -26,8 +26,7 @@ discard block |
||
26 | 26 | $array = array(); |
27 | 27 | try { |
28 | 28 | $node = simplexml_load_string($content); |
29 | - } |
|
30 | - catch(\Exception $e){ |
|
29 | + } catch(\Exception $e){ |
|
31 | 30 | return false; |
32 | 31 | } |
33 | 32 | |
@@ -61,7 +60,7 @@ discard block |
||
61 | 60 | ) |
62 | 61 | ); |
63 | 62 | } |
64 | - }else{ |
|
63 | + } else{ |
|
65 | 64 | $array[$name] = array(); |
66 | 65 | } |
67 | 66 | $array[$name][] = $res; |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | $listners = $this->doGetListeners(); |
105 | 105 | if (!$this->hadListeners($name, $object)){ |
106 | 106 | $res = false; |
107 | - }else{ |
|
107 | + } else{ |
|
108 | 108 | $listners = $this->doGetListeners(); |
109 | 109 | $res = (boolean) count($listners[$object][$name]); |
110 | 110 | } |
@@ -211,7 +211,7 @@ discard block |
||
211 | 211 | foreach($listeners as $listener){ |
212 | 212 | if($listener instanceof \PEIP\INF\Handler\Handler){ |
213 | 213 | $listener->handle($subject); |
214 | - }elseif(is_callable($listener)){ |
|
214 | + } elseif(is_callable($listener)){ |
|
215 | 215 | call_user_func($listener, $subject); |
216 | 216 | } |
217 | 217 | } |
@@ -70,10 +70,10 @@ |
||
70 | 70 | ), |
71 | 71 | $object |
72 | 72 | ); |
73 | - }else{ |
|
73 | + } else{ |
|
74 | 74 | throw new \InvalidArgumentException('instance of \PEIP\INF\Event\Event must contain subject'); |
75 | 75 | } |
76 | - }else{ |
|
76 | + } else{ |
|
77 | 77 | throw new \InvalidArgumentException('object must be instance of \PEIP\INF\Event\Event'); |
78 | 78 | } |
79 | 79 | } //put your code here |
@@ -116,8 +116,7 @@ |
||
116 | 116 | $this->send($content); |
117 | 117 | try { |
118 | 118 | $res = $this->receive(); |
119 | - } |
|
120 | - catch(\Exception $e){ |
|
119 | + } catch(\Exception $e){ |
|
121 | 120 | return NULL; |
122 | 121 | } |
123 | 122 | return $res; |
@@ -43,7 +43,7 @@ |
||
43 | 43 | class_exists($className); |
44 | 44 | $res = ReflectionPool::getInstance($className) |
45 | 45 | ->implementsInterface($interfaceName); |
46 | - } catch (\Exception $e){ |
|
46 | + } catch (\Exception $e){ |
|
47 | 47 | $res = false; |
48 | 48 | } |
49 | 49 | return $res;; |
@@ -77,7 +77,7 @@ |
||
77 | 77 | $this->inputChannel = $inputChannel; |
78 | 78 | if($this->inputChannel instanceof \PEIP\INF\Channel\SubscribableChannel){ |
79 | 79 | $this->inputChannel->subscribe($this); |
80 | - }else{ |
|
80 | + } else{ |
|
81 | 81 | $this->unwrapEvents = true; |
82 | 82 | $this->inputChannel->connect('postSend', $this); |
83 | 83 | } |
@@ -107,7 +107,7 @@ |
||
107 | 107 | while($iterator->valid()){ |
108 | 108 | if($iterator->isDir() && !$iterator->isDot()){ |
109 | 109 | $paths = self::findPaths($baseDir, $iterator->getChildren(), $paths); |
110 | - }elseif($iterator->isFile() && strrchr($iterator->getFilename(), '.') == '.php'){ |
|
110 | + } elseif($iterator->isFile() && strrchr($iterator->getFilename(), '.') == '.php'){ |
|
111 | 111 | $class = $iterator->getBasename('.php'); |
112 | 112 | $paths[$class] = str_replace($baseDir, '', $iterator->getPathName()); |
113 | 113 | } |