Skip to content

Commit

Permalink
fix extension install and preview issue (#1749)
Browse files Browse the repository at this point in the history
* fix extension install and preview issue

* image replaced
  • Loading branch information
vairafiq authored May 22, 2024
1 parent 85cae92 commit 49a2b68
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
2 changes: 1 addition & 1 deletion includes/classes/class-extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ public function has_match_in_active_plugins( $plugin_name = '' ) {
// get_the_products_list
public function setup_products_list() {

$url = 'https://app.directorist.com/wp-json/directorist/v1/get-remote-products';
$url = 'https://app.directorist.com/wp-json/directorist/v1/get-remote-products?' . ATBDP_VERSION;
$headers = array(
'user-agent' => 'Directorist/' . md5( esc_url( home_url() ) ) . ';',
'Accept' => 'application/json',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,13 +138,7 @@
<input type="checkbox" id="<?php echo esc_attr( $extension_base ); ?>" name="<?php echo esc_attr( $extension_base ); ?>" class="extension-name-checkbox">
<label class="directorist-checkbox__label" for="<?php echo esc_attr( $extension_base ); ?>">
<?php
$img = 'https://via.placeholder.com/44';

if ( ! empty($args['extension_list'][$extension_base] ) ) {
$img = $args['extension_list'][$extension_base]['thumbnail'];
} else if ( ! empty( $args['extension_list'][$extension_base_alias] ) ) {
$img = $args['extension_list'][$extension_base_alias]['thumbnail'];
}
$img = ! empty( $extension['thumbnail'] ) ? $extension['thumbnail'] : DIRECTORIST_ASSETS . 'images/no-image.png';
?>
<img src="<?php echo esc_url( $img ); ?>" width="44" height="44" alt=""><?php echo esc_html( $extension['title'] ) ?>
</label>
Expand Down

0 comments on commit 49a2b68

Please sign in to comment.