8000 Fixed dependency check for fpdfWriter by MaximilianKresse · Pull Request #262 · endroid/qr-code · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fixed dependency check for fpdfWriter #262

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send yo 8000 u account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions src/Writer/FpdfWriter.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,17 @@ class FpdfWriter extends AbstractWriter
public const WRITER_OPTION_MEASURE_UNIT = 'fpdf_measure_unit';

public function __construct()
{
}

public function writeString(QrCodeInterface $qrCode): string
{
if(!\class_exists(\FPDF::class)){
throw new \BadMethodCallException(
'The Fpdf writer requires FPDF as dependency but the class "\\FPDF" couldn\'t be found.'
);
}
}

public function writeString(QrCodeInterface $qrCode): string
{

if ($qrCode->getValidateResult()) {
throw new ValidationException(
'Built-in validation reader can not check fpdf qr codes: please disable via setValidateResult(false)'
Expand Down
0