Skip to content

Commit

Permalink
fix: dokan_is_store_listing function (#726)
Browse files Browse the repository at this point in the history
  • Loading branch information
saimonh3 authored and sabbir1991 committed Jan 2, 2020
1 parent 5580f90 commit d24c88e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 11 deletions.
1 change: 1 addition & 0 deletions assets/src/less/store-lists.less
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@
.apply-filter {
display: flex;
justify-content: flex-end;
margin-top: 20px;

#cancel-filter-btn {
padding: 8px 25px;
Expand Down
12 changes: 1 addition & 11 deletions includes/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -3423,17 +3423,7 @@ function dokan_get_permalink( $page_id ) {
* @return boolean
*/
function dokan_is_store_listing() {
$page_id = dokan_get_option( 'store_listing', 'dokan_pages' );

if ( ! $page_id ) {
return false;
}

if ( $page_id === get_the_ID() ) {
return true;
}

return false;
return get_the_ID() === intval( dokan_get_option( 'store_listing', 'dokan_pages' ) );
}

/**
Expand Down

0 comments on commit d24c88e

Please sign in to comment.