Permalink
Browse files

* remove debug code

 * force array type (Commands::pear2skeleton)
 * don't inject $args (since it's not necessary used)
  • Loading branch information...
1 parent dab0001 commit 5caf7f01631aaa55079d3c9e2944f5dc9f517a58 @till till committed Jul 13, 2011
View
8 src/Pyrus/Developer/PackageFile/Commands.php
@@ -435,7 +435,7 @@ function runTests($frontend, $args, $options)
/**
* Create the PEAR2 skeleton
*
- * @param mixed $frontend
+ * @param mixed $frontend \Pyrus\ScriptFrontend\Commands
* @param array $args
* @param array $options
*
@@ -444,17 +444,15 @@ function runTests($frontend, $args, $options)
* @uses Pyrus\Developer\PackageFile\Commands\PEAR2Skeleton
* @uses self::makePackageXml()
*/
- public function pear2Skeleton($frontend, $args, $options)
+ public function pear2Skeleton($frontend, array $args, array $options)
{
if (!isset($args['channel'])) {
$args['channel'] = 'pear2.php.net';
}
$info = $this->parsePackageName($args['package'], $args['channel']);
- var_dump($frontend, $info, $args);
- exit;
- $skeleton = new Commands\PEAR2Skeleton($args, $info);
+ $skeleton = new Commands\PEAR2Skeleton($info);
$skeleton->generate();
$options['stub'] = $skeleton->getStub();
View
9 src/Pyrus/Developer/PackageFile/Commands/PEAR2Skeleton.php
@@ -14,11 +14,6 @@
class PEAR2Skeleton
{
/**
- * @var array $args
- */
- protected $args;
-
- /**
* @var array $info
*/
protected $info;
@@ -51,15 +46,14 @@ class PEAR2Skeleton
/**
* __construct
*
- * @param array $args
* @param array $info
* @param string $format
*
* @return $this
* @throws \Pyrus\Developer\Creator\Exception When the path of the package does
* not exist.
*/
- public function __construct(array $args, array $info, $format = 'simple')
+ public function __construct(array $info, $format = 'simple')
{
if (file_exists($info['path'])) {
throw new \Pyrus\Developer\Creator\Exception(
@@ -73,7 +67,6 @@ public function __construct(array $args, array $info, $format = 'simple')
);
}
- $this->args = $args;
$this->info = $info;
$this->templatePath = __DIR__ . '/templates';

0 comments on commit 5caf7f0

Please sign in to comment.