Plugin Directory

Changeset 1730017


Ignore:
Timestamp:
09/14/2017 03:14:37 PM (8 years ago)
Author:
kstover
Message:

Adding extra checks to make sure opted in users aren't opted in again.

Location:
ninja-forms
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • ninja-forms/tags/3.2/lib/NF_Tracking.php

    r1729967 r1730017  
    4949            $opt_in_action = htmlspecialchars( $_GET[ self::FLAG ] );
    5050
    51             if( self::OPT_IN == $opt_in_action ){
     51            if( self::OPT_IN == $opt_in_action && ! $this->is_opted_in() ){
    5252                $this->opt_in();
    5353            }
    5454
    55             if( self::OPT_OUT == $opt_in_action ){
     55            if( self::OPT_OUT == $opt_in_action && ! $this->is_opted_out() ){
    5656                $this->opt_out();
    5757            }
  • ninja-forms/trunk/lib/NF_Tracking.php

    r1729967 r1730017  
    4949            $opt_in_action = htmlspecialchars( $_GET[ self::FLAG ] );
    5050
    51             if( self::OPT_IN == $opt_in_action ){
     51            if( self::OPT_IN == $opt_in_action && ! $this->is_opted_in() ){
    5252                $this->opt_in();
    5353            }
    5454
    55             if( self::OPT_OUT == $opt_in_action ){
     55            if( self::OPT_OUT == $opt_in_action && ! $this->is_opted_out() ){
    5656                $this->opt_out();
    5757            }
Note: See TracChangeset for help on using the changeset viewer.