Auto Terms of Service and Privacy Policy - Version 2.2.6

Version Description

Download this release

Release Info

Developer wpautoterms
Plugin Icon Auto Terms of Service and Privacy Policy
Version 2.2.6
Comparing to
See all releases

Code changes from version 2.2.5 to 2.2.6

README.txt CHANGED
@@ -4,7 +4,7 @@ Tags: gdpr, privacy policy, terms and conditions, cookie consent, terms of servi
4
  Requires at least: 4.2
5
  Tested up to: 5.1.1
6
  Requires PHP: 5.3
7
- Stable tag: 2.2.5
8
  License: GPL version 3 or any later version
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -119,6 +119,10 @@ Installing the plugin is easy. Just follow these steps:
119
 
120
  == Changelog ==
121
 
 
 
 
 
122
  = Version 2.2.5 =
123
  * Apr 9, 2019
124
  * Bug fix: Legal Page won't appear under the Category page
4
  Requires at least: 4.2
5
  Tested up to: 5.1.1
6
  Requires PHP: 5.3
7
+ Stable tag: 2.2.6
8
  License: GPL version 3 or any later version
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
119
 
120
  == Changelog ==
121
 
122
+ = Version 2.2.6 =
123
+ * Apr 24, 2019
124
+ * Bug fix: Category Links incorrectly appear in Links to Legal Pages kit
125
+
126
  = Version 2.2.5 =
127
  * Apr 9, 2019
128
  * Bug fix: Legal Page won't appear under the Category page
auto-terms-of-service-privacy-policy.php CHANGED
@@ -5,7 +5,7 @@ Plugin URI: https://wpautoterms.com
5
  Description: Create Privacy Policy, GDPR Privacy Policy, Terms & Conditions, Disclaimers. Cookie Consent Banner. More Compliance Kits to help you get compliant with the law.
6
  Author: WP AutoTerms
7
  Author URI: https://wpautoterms.com
8
- Version: 2.2.5
9
  License: GPLv2 or later
10
  Text Domain: wpautoterms
11
  Domain Path: /languages
5
  Description: Create Privacy Policy, GDPR Privacy Policy, Terms & Conditions, Disclaimers. Cookie Consent Banner. More Compliance Kits to help you get compliant with the law.
6
  Author: WP AutoTerms
7
  Author URI: https://wpautoterms.com
8
+ Version: 2.2.6
9
  License: GPLv2 or later
10
  Text Domain: wpautoterms
11
  Domain Path: /languages
bitbucket-pipelines.yml ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # This is a sample build configuration for Docker.
2
+ # Check our guides at https://confluence.atlassian.com/x/O1toN for more examples.
3
+ # Only use spaces to indent your .yml configuration.
4
+ # -----
5
+ # You can specify a custom docker image from Docker Hub as your build environment.
6
+ image: atlassian/default-image:2
7
+
8
+ pipelines:
9
+ default:
10
+ - step:
11
+ services:
12
+ - docker
13
+ script: # Modify the commands below to build your repository.
14
+ # Set $DOCKER_HUB_USERNAME and $DOCKER_HUB_PASSWORD as environment variables in repository settings
15
+ - export IMAGE_NAME=your-Dockerhub-account/your-docker-image-name:$BITBUCKET_COMMIT
16
+
17
+ # build the Docker image (this will use the Dockerfile in the root of the repo)
18
+ - docker build -t $IMAGE_NAME .
19
+ # authenticate with the Docker Hub registry
20
+ - docker login --username $DOCKER_HUB_USERNAME --password $DOCKER_HUB_PASSWORD
21
+ # push the new Docker image to the Docker registry
22
+ - docker push $IMAGE_NAME
includes/frontend/links.php CHANGED
@@ -24,14 +24,19 @@ class Links {
24
  if ( ! get_option( WPAUTOTERMS_OPTION_PREFIX . static::MODULE_ID ) ) {
25
  return;
26
  }
 
27
  $args = array(
28
- 'post_type' => CPT::type(),
29
  'post_status' => 'publish',
30
  'orderby' => 'post_modified',
31
  'numberposts' => - 1
32
  );
33
 
34
  $posts = get_posts( $args );
 
 
 
 
35
  $new_page = $custom = get_option( static::_option_prefix() . '_target_blank' );
36
  \wpautoterms\print_template( static::MODULE_ID, compact( 'posts', 'new_page' ) );
37
  }
24
  if ( ! get_option( WPAUTOTERMS_OPTION_PREFIX . static::MODULE_ID ) ) {
25
  return;
26
  }
27
+ $wp_type = CPT::type();
28
  $args = array(
29
+ 'post_type' => $wp_type,
30
  'post_status' => 'publish',
31
  'orderby' => 'post_modified',
32
  'numberposts' => - 1
33
  );
34
 
35
  $posts = get_posts( $args );
36
+ // Filter out by post type, category page adds "post" in filter.
37
+ $posts = array_filter( $posts, function ( \WP_Post $x ) use ( $wp_type ) {
38
+ return $x->post_type == $wp_type;
39
+ } );
40
  $new_page = $custom = get_option( static::_option_prefix() . '_target_blank' );
41
  \wpautoterms\print_template( static::MODULE_ID, compact( 'posts', 'new_page' ) );
42
  }