Remove useless constructors
This commit is contained in:
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class NewsletterLink extends Model {
|
||||
public static $_table = MP_NEWSLETTER_LINKS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class NewsletterOption extends Model {
|
||||
public static $_table = MP_NEWSLETTER_OPTION_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class NewsletterPost extends Model {
|
||||
public static $_table = MP_NEWSLETTER_POSTS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class NewsletterSegment extends Model {
|
||||
public static $_table = MP_NEWSLETTER_SEGMENT_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
||||
|
@ -10,10 +10,6 @@ class SendingQueue extends Model {
|
||||
const STATUS_SCHEDULED = 'scheduled';
|
||||
const STATUS_PAUSED = 'paused';
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
function pause() {
|
||||
if($this->count_processed === $this->count_total) {
|
||||
return false;
|
||||
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class StatisticsClicks extends Model {
|
||||
public static $_table = MP_STATISTICS_CLICKS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
@ -6,10 +6,6 @@ if(!defined('ABSPATH')) exit;
|
||||
class StatisticsForms extends Model {
|
||||
public static $_table = MP_STATISTICS_FORMS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
public static function record($form_id, $subscriber_id) {
|
||||
if($form_id > 0 && $subscriber_id > 0) {
|
||||
// check if we already have a record for today
|
||||
|
@ -6,10 +6,6 @@ if(!defined('ABSPATH')) exit;
|
||||
class StatisticsNewsletters extends Model {
|
||||
public static $_table = MP_STATISTICS_NEWSLETTERS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
static function createMultiple(array $data) {
|
||||
$values = array();
|
||||
foreach($data as $value) {
|
||||
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class StatisticsOpens extends Model {
|
||||
public static $_table = MP_STATISTICS_OPENS_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
@ -5,8 +5,4 @@ if(!defined('ABSPATH')) exit;
|
||||
|
||||
class StatisticsUnsubscribes extends Model {
|
||||
public static $_table = MP_STATISTICS_UNSUBSCRIBES_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
}
|
@ -8,10 +8,6 @@ if(!defined('ABSPATH')) exit;
|
||||
class SubscriberCustomField extends Model {
|
||||
public static $_table = MP_SUBSCRIBER_CUSTOM_FIELD_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
static function createOrUpdate($data = array()) {
|
||||
$custom_field = CustomField::findOne($data['custom_field_id']);
|
||||
if($custom_field === false) {
|
||||
|
@ -8,10 +8,6 @@ if(!defined('ABSPATH')) exit;
|
||||
class SubscriberSegment extends Model {
|
||||
public static $_table = MP_SUBSCRIBER_SEGMENT_TABLE;
|
||||
|
||||
function __construct() {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
function subscriber() {
|
||||
return $this->has_one(__NAMESPACE__.'\Subscriber', 'id', 'subscriber_id');
|
||||
}
|
||||
|
Reference in New Issue
Block a user