Completed
Push — support/2.0 ( 978a1e...05f0de )
by Vítor
03:16
created
PPI/Templating/Twig/Extension/RouterExtension.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
      *
32 32
      * @param UrlGeneratorInterface $generator
33 33
      *
34
-     * @return void
34
+     * @return \Twig_ExtensionInterface
35 35
      */
36 36
     public function __construct(UrlGeneratorInterface $generator)
37 37
     {
Please login to merge, or discard this patch.
PPI/Templating/Twig/Loader/FileSystemLoader.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
      * @param FileLocatorInterface        $locator A FileLocatorInterface instance
42 42
      * @param TemplateNameParserInterface $parser  A TemplateNameParserInterface instance
43 43
      *
44
-     * @return void
44
+     * @return null|\Twig_LoaderInterface
45 45
      */
46 46
     public function __construct(FileLocatorInterface $locator, TemplateNameParserInterface $parser)
47 47
     {
Please login to merge, or discard this patch.
Unused Use Statements   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,8 +8,8 @@
 block discarded – undo
8 8
  */
9 9
 namespace PPI\Templating\Twig\Loader;
10 10
 
11
-use Symfony\Component\Templating\TemplateNameParserInterface,
12
-    Symfony\Component\Config\FileLocatorInterface;
11
+use Symfony\Component\Templating\TemplateNameParserInterface;
12
+use Symfony\Component\Config\FileLocatorInterface;
13 13
 
14 14
 /**
15 15
  * FilesystemLoader extends the default Twig filesystem loader
Please login to merge, or discard this patch.
PPI/Templating/Twig/TwigEngine.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
     /**
71 71
      * Renders a template.
72 72
      *
73
-     * @param mixed $name       A template name
73
+     * @param string $name       A template name
74 74
      * @param array $parameters An array of parameters to pass to the template
75 75
      *
76 76
      * @throws \InvalidArgumentException if the template does not exist
Please login to merge, or discard this patch.
Unused Use Statements   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -10,13 +10,13 @@
 block discarded – undo
10 10
 
11 11
 namespace PPI\Templating\Twig;
12 12
 
13
-use PPI\Templating\TemplateReference,
14
-    PPI\Templating\EngineInterface,
15
-    PPI\Templating\GlobalVariables,
16
-    Symfony\Component\Templating\TemplateNameParserInterface,
17
-    Symfony\Component\Templating\StreamingEngineInterface,
18
-    Symfony\Component\HttpFoundation\Response,
19
-    Symfony\Component\Config\FileLocatorInterface;
13
+use PPI\Templating\TemplateReference;
14
+use PPI\Templating\EngineInterface;
15
+use PPI\Templating\GlobalVariables;
16
+use Symfony\Component\Templating\TemplateNameParserInterface;
17
+use Symfony\Component\Templating\StreamingEngineInterface;
18
+use Symfony\Component\HttpFoundation\Response;
19
+use Symfony\Component\Config\FileLocatorInterface;
20 20
 
21 21
 /**
22 22
  * This engine knows how to render Twig templates.
Please login to merge, or discard this patch.
PPI/Templating/FileLocator.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -81,9 +81,9 @@
 block discarded – undo
81 81
     {
82 82
 
83 83
         if ('@' === $file[0]) {
84
-           if (false !== strpos($file, '..')) {
85
-               throw new \RuntimeException(sprintf('File name "%s" contains invalid characters (..).', $file));
86
-           }
84
+            if (false !== strpos($file, '..')) {
85
+                throw new \RuntimeException(sprintf('File name "%s" contains invalid characters (..).', $file));
86
+            }
87 87
 
88 88
             $path = $this->baseModulePath . '/' . substr($file, 1);
89 89
             if (file_exists($path)) {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -124,7 +124,7 @@
 block discarded – undo
124 124
         $paths = array();
125 125
 
126 126
         foreach ($this->modules as $module) {
127
-            $paths[$module] = $this->baseModulePath.DIRECTORY_SEPARATOR.$module;
127
+            $paths[$module] = $this->baseModulePath . DIRECTORY_SEPARATOR . $module;
128 128
         }
129 129
 
130 130
         return $paths;
Please login to merge, or discard this patch.
PPI/Templating/GlobalVariables.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
      */
89 89
     public function offsetExists($property)
90 90
     {
91
-        return method_exists($this, 'get'.ucfirst($property));
91
+        return method_exists($this, 'get' . ucfirst($property));
92 92
     }
93 93
 
94 94
     /**
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
      */
97 97
     public function offsetGet($property)
98 98
     {
99
-        return call_user_func(array($this, 'get'.ucfirst($property)));
99
+        return call_user_func(array($this, 'get' . ucfirst($property)));
100 100
     }
101 101
 
102 102
     /**
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
      */
105 105
     public function offsetSet($property, $value)
106 106
     {
107
-        throw new \RuntimeException('Usage of '.__METHOD__.' is not allowed');
107
+        throw new \RuntimeException('Usage of ' . __METHOD__ . ' is not allowed');
108 108
     }
109 109
 
110 110
     /**
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
      */
113 113
     public function offsetUnset($property)
114 114
     {
115
-        throw new \RuntimeException('Usage of '.__METHOD__.' is not allowed');
115
+        throw new \RuntimeException('Usage of ' . __METHOD__ . ' is not allowed');
116 116
     }
117 117
 
118 118
 }
Please login to merge, or discard this patch.
PPI/Templating/Twig/Extension/AssetsExtension.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
      * Returns a list of functions to add to the existing list.
42 42
      *
43 43
      * @return array An array of functions
44
-    */
44
+     */
45 45
     public function getFunctions()
46 46
     {
47 47
         return array(
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
      * @param string $packageName The name of the asset package to use
60 60
      *
61 61
      * @return string A public path which takes into account the base path and URL path
62
-    */
62
+     */
63 63
     public function getAssetUrl($path, $packageName = null)
64 64
     {
65 65
         return $this->assetsHelper->getUrl($path, $packageName);
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
      * @param string $packageName
72 72
      *
73 73
      * @return integer
74
-    */
74
+     */
75 75
     public function getAssetsVersion($packageName = null)
76 76
     {
77 77
         return $this->assetsHelper->getVersion($packageName);
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
      * Returns the name of the extension.
82 82
      *
83 83
      * @return string The extension name
84
-    */
84
+     */
85 85
     public function getName()
86 86
     {
87 87
         return 'assets';
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
      *
32 32
      * @param UrlGeneratorInterface $generator
33 33
      *
34
-     * @return void
34
+     * @return \Twig_ExtensionInterface
35 35
      */
36 36
     public function __construct(UrlGeneratorInterface $generator)
37 37
     {
Please login to merge, or discard this patch.
PPI/Templating/TemplateReference.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -68,9 +68,9 @@
 block discarded – undo
68 68
     {
69 69
         $controller = str_replace('\\', '/', $this->get('controller'));
70 70
 
71
-        $path = (empty($controller) ? '' : $controller.'/').$this->get('name').'.'.$this->get('format').'.'.$this->get('engine');
71
+        $path = (empty($controller) ? '' : $controller . '/') . $this->get('name') . '.' . $this->get('format') . '.' . $this->get('engine');
72 72
 
73
-        return empty($this->parameters['module']) ? self::APP_VIEWS_DIRECTORY.'/'.$path : '@'.$this->get('module').'/'.self::MODULE_VIEWS_DIRECTORY.'/'.$path;
73
+        return empty($this->parameters['module']) ? self::APP_VIEWS_DIRECTORY . '/' . $path : '@' . $this->get('module') . '/' . self::MODULE_VIEWS_DIRECTORY . '/' . $path;
74 74
     }
75 75
 
76 76
     /**
Please login to merge, or discard this patch.
PPI/Templating/Smarty/Extension/RouterExtension.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -6,17 +6,17 @@
 block discarded – undo
6 6
  * @license    http://opensource.org/licenses/mit-license.php MIT
7 7
  * @link       http://www.ppi.io
8 8
  */
9
- namespace PPI\Templating\Smarty\Extension;
9
+    namespace PPI\Templating\Smarty\Extension;
10 10
 
11
- use NoiseLabs\Bundle\SmartyBundle\Extension\RoutingExtension as BaseRoutingExtension;
11
+    use NoiseLabs\Bundle\SmartyBundle\Extension\RoutingExtension as BaseRoutingExtension;
12 12
 
13
- /**
14
-  * Provides integration of the Routing component with Smarty[Bundle].
15
-  *
16
-  * @author     Vítor Brandão <[email protected]>
17
-  * @package    PPI
18
-  * @subpackage Templating
19
-  */
20
- class RouterExtension extends BaseRoutingExtension
21
- {
22
- }
13
+    /**
14
+     * Provides integration of the Routing component with Smarty[Bundle].
15
+     *
16
+     * @author     Vítor Brandão <[email protected]>
17
+     * @package    PPI
18
+     * @subpackage Templating
19
+     */
20
+    class RouterExtension extends BaseRoutingExtension
21
+    {
22
+    }
Please login to merge, or discard this patch.
PPI/Tests/Exception/LogTest.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -9,19 +9,19 @@
 block discarded – undo
9 9
 namespace PPI\Tests\Exception;
10 10
 
11 11
 use PPI\Test\Unit,
12
-	PPI\Exception\Log;
12
+    PPI\Exception\Log;
13 13
 
14 14
 class LogTest extends Unit {
15 15
 
16
-	public $logger;
16
+    public $logger;
17 17
 
18
-	public function setUp() {
19
-		$this->logger = new Log();
20
-	}
18
+    public function setUp() {
19
+        $this->logger = new Log();
20
+    }
21 21
 
22
-	public function testSetLogFile() {
23
-		$this->logger->setLogFile('foobar');
24
-		$this->assertAttributeContains('foobar', '_logFile', $this->logger);
25
-	}
22
+    public function testSetLogFile() {
23
+        $this->logger->setLogFile('foobar');
24
+        $this->assertAttributeContains('foobar', '_logFile', $this->logger);
25
+    }
26 26
 
27 27
 }
28 28
\ No newline at end of file
Please login to merge, or discard this patch.