We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi,
there is a PHP notice with orders that were created before using Dokan.
PHP Notice: Trying to get property 'display_name' of non-object in /wp/wp-content/plugins/dokan-master/includes/admin-functions.php on line 117
That should fix the error: $seller = get_user_by( 'id', dokan_get_seller_id_by_order( $post->ID ) ); if( $seller ) { printf( '<a href="%s">%s</a>', esc_url( admin_url( 'edit.php?post_type=shop_order&vendor_id=' . $seller->ID ) ), esc_html( $seller->display_name ) ); }
$seller = get_user_by( 'id', dokan_get_seller_id_by_order( $post->ID ) ); if( $seller ) { printf( '<a href="%s">%s</a>', esc_url( admin_url( 'edit.php?post_type=shop_order&vendor_id=' . $seller->ID ) ), esc_html( $seller->display_name ) ); }
The text was updated successfully, but these errors were encountered:
fix: use correct function to retrieve seller id from an order is fixed …
5d766dd
…getdokan#515
1f893c4
No branches or pull requests
Hi,
there is a PHP notice with orders that were created before using Dokan.
PHP Notice: Trying to get property 'display_name' of non-object in /wp/wp-content/plugins/dokan-master/includes/admin-functions.php on line 117
That should fix the error:
$seller = get_user_by( 'id', dokan_get_seller_id_by_order( $post->ID ) ); if( $seller ) { printf( '<a href="%s">%s</a>', esc_url( admin_url( 'edit.php?post_type=shop_order&vendor_id=' . $seller->ID ) ), esc_html( $seller->display_name ) ); }
The text was updated successfully, but these errors were encountered: