mirror of
https://github.com/chillerlan/php-qrcode.git
synced 2026-10-09 21:35:53 +00:00
:octocat: mark nullable types explicitly (https://github.com/chillerlan/php-qrcode/issues/276)
This commit is contained in:
@@ -48,7 +48,7 @@ class MyCustomOutput extends QROutputAbstract{
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
public function dump(string $file = null):string{
|
||||
public function dump(string|null $file = null):string{
|
||||
$output = '';
|
||||
|
||||
for($y = 0; $y < $this->moduleCount; $y++){
|
||||
|
||||
@@ -30,7 +30,7 @@ class QRImageWithLogo extends QRGdImagePNG{
|
||||
* @return string
|
||||
* @throws \chillerlan\QRCode\Output\QRCodeOutputException
|
||||
*/
|
||||
public function dump(string $file = null, string $logo = null):string{
|
||||
public function dump(string|null $file = null, string|null $logo = null):string{
|
||||
// set returnResource to true to skip further processing for now
|
||||
$this->options->returnResource = true;
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ class QRImageWithText extends QRGdImagePNG{
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
public function dump(string $file = null, string $text = null):string{
|
||||
public function dump(string|null $file = null, string|null $text = null):string{
|
||||
// set returnResource to true to skip further processing for now
|
||||
$this->options->returnResource = true;
|
||||
|
||||
|
||||
@@ -47,7 +47,7 @@ class SVGConvert extends QRMarkupSVG{
|
||||
}
|
||||
|
||||
/** @inheritDoc */
|
||||
public function dump(string $file = null):string{
|
||||
public function dump(string|null $file = null):string{
|
||||
$base64 = $this->options->outputBase64;
|
||||
// we don't want the SVG in base64
|
||||
$this->options->outputBase64 = false;
|
||||
|
||||
@@ -28,7 +28,7 @@ class QRImagickWithLogo extends QRImagick{
|
||||
* @inheritDoc
|
||||
* @throws \chillerlan\QRCode\Output\QRCodeOutputException
|
||||
*/
|
||||
public function dump(string $file = null):string{
|
||||
public function dump(string|null $file = null):string{
|
||||
// set returnResource to true to skip further processing for now
|
||||
$this->options->returnResource = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user