Skip to content

Commit

Permalink
Pass optional license to authorize button
Browse files Browse the repository at this point in the history
tarecord committed Aug 26, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent a3a8578 commit fbfa55a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/Uplink/functions.php
Original file line number Diff line number Diff line change
@@ -38,12 +38,13 @@ function get_container(): ContainerInterface {
* @param string $slug The Product slug to render the button for.
* @param string $domain An optional domain associated with a license key to pass along.
*/
function render_authorize_button( string $slug, string $domain = '' ): void {
function render_authorize_button( string $slug, string $domain = '', string $license = '' ): void {
try {
get_container()->get( Authorize_Button_Controller::class )
->render( [
'slug' => $slug,
'domain' => $domain,
'slug' => $slug,
'domain' => $domain,
'license' => $license,
] );
} catch ( Throwable $e ) {
if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) {

0 comments on commit fbfa55a

Please sign in to comment.