Skip to content

Commit

Permalink
Make options optional arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
mbontemps committed Jul 21, 2011
1 parent 71feb5a commit 124e1dd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/Knp/Snappy/AbstractGenerator.php
Expand Up @@ -22,7 +22,7 @@ abstract class AbstractGenerator implements GeneratorInterface
* @param string $binary
* @param array $options
*/
public function __construct($binary, array $options)
public function __construct($binary, array $options = array())
{
$this->configure();

Expand Down Expand Up @@ -306,7 +306,7 @@ protected function createTemporaryFile($content = null, $extension = null)
*
* @return string
*/
protected function buildCommand($binary, $input, $output, array $options)
protected function buildCommand($binary, $input, $output, array $options = array())
{
$command = $binary;

Expand Down
8 changes: 4 additions & 4 deletions src/Knp/Snappy/GeneratorInterface.php
Expand Up @@ -19,7 +19,7 @@ interface GeneratorInterface
* @param string $output The output media filename
* @param array $options An array of options for this generation only
*/
function generate($input, $output, array $options, $overwrite);
function generate($input, $output, array $options = array(), $overwrite);

/**
* Generates the output media file from the given HTML
Expand All @@ -28,7 +28,7 @@ function generate($input, $output, array $options, $overwrite);
* @param string $output The output media filename
* @param array $options An array of options for this generation only
*/
function generateFromHtml($html, $output, array $options, $overwrite);
function generateFromHtml($html, $output, array $options = array(), $overwrite);

/**
* Returns the output of the media generated from the specified input HTML
Expand All @@ -39,7 +39,7 @@ function generateFromHtml($html, $output, array $options, $overwrite);
*
* @return string
*/
function getOutput($input, array $options);
function getOutput($input, array $options = array());

/**
* Returns the output of the media generated from the given HTML
Expand All @@ -49,5 +49,5 @@ function getOutput($input, array $options);
*
* @return string
*/
function getOutputFromHtml($html, array $options);
function getOutputFromHtml($html, array $options = array());
}

0 comments on commit 124e1dd

Please sign in to comment.