PluginProbe
SellKit – Funnel builder and checkout optimizer for WooCommerce to sell more, faster / 2.3.0
SellKit – Funnel builder and checkout optimizer for WooCommerce to sell more, faster v2.3.0
2.6.0 trunk 1.1.0 1.1.4 1.2.1 1.2.2 1.2.3 1.2.5 1.2.9 1.3.1 1.3.2 1.5.0 1.5.1 1.5.4 1.5.7 1.5.8 1.5.9 1.6.2 1.6.5 1.6.8 1.7.2 1.7.4 1.7.5 1.7.9 1.8.1 All 42 releases
← All changes | includes/db.php +22 -1 1.2.92.3.0 View file →
@@ -75,8 +75,25 @@
75 75 applied_at VARCHAR(20),
76 76 PRIMARY KEY ( id )
77 77 ',
78 78 ],
79 + 'funnel_contact' => [
80 + 'name' => $wpdb->prefix . self::DATABASE_PREFIX . 'funnel_contact',
81 + 'query' => '
82 + id bigint(20) NOT NULL AUTO_INCREMENT,
83 + funnel_id bigint(20) NOT NULL,
84 + user_id bigint(20) NOT NULL,
85 + order_bump longtext DEFAULT NULL,
86 + upsell longtext DEFAULT NULL,
87 + downsell longtext DEFAULT NULL,
88 + optin longtext DEFAULT NULL,
89 + checkout longtext DEFAULT NULL,
90 + total_spent longtext DEFAULT NULL,
91 + updated_at VARCHAR(11),
92 + created_at VARCHAR(11),
93 + PRIMARY KEY ( id )
94 + ',
95 + ],
79 96 ];
80 97
81 98 return apply_filters( 'sellkit_tables', $tables );
82 99 }
@@ -198,9 +215,13 @@
198 215
199 216 // phpcs:ignore WordPress.DB.DirectDatabaseQuery
200 217 $result = $wpdb->insert( $wpdb->prefix . self::DATABASE_PREFIX . $table_name, $prepared_data, $format );
201 218
202 - return $result;
219 + if ( empty( $result ) || is_wp_error( $result ) ) {
220 + return false;
221 + }
222 +
223 + return $wpdb->insert_id;
203 224 }
204 225
205 226 /**
206 227 * Gets database data.