Skip to content
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 you account related emails.

Already on GitHub? Sign in to your account

SP-600 Test EDD Improvements #13

Merged
merged 2 commits into from
Aug 9, 2023
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
6 changes: 3 additions & 3 deletions BitPayEddLib/class-bitpayinvoicefactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ private function get_notification_url(): string {
}

private function get_buyer(): Buyer {
if ( $this->get_edd_option( 'bitpay_checkout_capture_email' ) !== 1 ) {
if ( ! $this->get_edd_option( 'bitpay_checkout_capture_email' ) ) {
return new Buyer();
}

Expand All @@ -51,9 +51,9 @@ private function get_buyer(): Buyer {
return $buyer_info;
}

private function get_edd_option( string $option_name ): string {
private function get_edd_option( string $option_name ): ?string {
global $edd_options;

return $edd_options[ $option_name ];
return $edd_options[ $option_name ] ?? null;
}
}