MW WP Form - Version 3.2.1

Version Description

  • Bugfix : Fixed a bug that displayed send error page when admin mail address is false.
Download this release

Release Info

Developer inc2734
Plugin Icon wp plugin MW WP Form
Version 3.2.1
Comparing to
See all releases

Code changes from version 3.2.0 to 3.2.1

classes/models/class.mail.php CHANGED
@@ -2,11 +2,11 @@
2
  /**
3
  * Name : MW WP Form Mail
4
  * Description: メールクラス
5
- * Version : 2.2.0
6
  * Author : Takashi Kitajima
7
  * Author URI : http://2inc.org
8
  * Created : July 20, 2012
9
- * Modified : April 29, 2017
10
  * License : GPLv2 or later
11
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
  */
@@ -77,8 +77,8 @@ class MW_WP_Form_Mail {
77
  * @return boolean
78
  */
79
  public function send() {
80
- if ( !$this->to ) {
81
- return;
82
  }
83
 
84
  $sender = $this->sender;
2
  /**
3
  * Name : MW WP Form Mail
4
  * Description: メールクラス
5
+ * Version : 2.2.1
6
  * Author : Takashi Kitajima
7
  * Author URI : http://2inc.org
8
  * Created : July 20, 2012
9
+ * Modified : May 4, 2017
10
  * License : GPLv2 or later
11
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
  */
77
  * @return boolean
78
  */
79
  public function send() {
80
+ if ( ! $this->to ) {
81
+ return apply_filters( 'mwform_is_mail_sended', false );
82
  }
83
 
84
  $sender = $this->sender;
classes/services/class.mail.php CHANGED
@@ -1,11 +1,11 @@
1
  <?php
2
  /**
3
  * Name : MW WP Form Mail Service
4
- * Version : 1.4.0
5
  * Author : Takashi Kitajima
6
  * Author URI : http://2inc.org
7
  * Created : January 1, 2015
8
- * Modified : April 29, 2017
9
  * License : GPLv2 or later
10
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
  */
@@ -98,6 +98,12 @@ class MW_WP_Form_Mail_Service {
98
  );
99
  $is_admin_mail_sended = $Mail_admin->send();
100
 
 
 
 
 
 
 
101
  if ( isset( $Mail_admin_for_save ) && $is_admin_mail_sended ) {
102
  $saved_mail_id = $this->save( $Mail_admin_for_save );
103
  $Contact_Data_Setting = new MW_WP_Form_Contact_Data_Setting( $saved_mail_id );
1
  <?php
2
  /**
3
  * Name : MW WP Form Mail Service
4
+ * Version : 1.4.1
5
  * Author : Takashi Kitajima
6
  * Author URI : http://2inc.org
7
  * Created : January 1, 2015
8
+ * Modified : May 4, 2017
9
  * License : GPLv2 or later
10
  * License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
  */
98
  );
99
  $is_admin_mail_sended = $Mail_admin->send();
100
 
101
+ // to が false の場合は意図的に送信していない(例えばDB保存だけおこないたい等)ということなので
102
+ // 送信エラー画面が表示されるのはおかしい。そのためここでは true を返す
103
+ if ( ! $Mail_admin->to ) {
104
+ $is_admin_mail_sended = true;
105
+ }
106
+
107
  if ( isset( $Mail_admin_for_save ) && $is_admin_mail_sended ) {
108
  $saved_mail_id = $this->save( $Mail_admin_for_save );
109
  $Contact_Data_Setting = new MW_WP_Form_Contact_Data_Setting( $saved_mail_id );
mw-wp-form.php CHANGED
@@ -3,11 +3,11 @@
3
  * Plugin Name: MW WP Form
4
  * Plugin URI: http://plugins.2inc.org/mw-wp-form/
5
  * Description: MW WP Form is shortcode base contact form plugin. This plugin have many feature. For example you can use many validation rules, contact data saving, and chart aggregation using saved contact data.
6
- * Version: 3.2.0
7
  * Author: Takashi Kitajima
8
  * Author URI: http://2inc.org
9
  * Created : September 25, 2012
10
- * Modified: April 29, 2017
11
  * Text Domain: mw-wp-form
12
  * Domain Path: /languages/
13
  * License: GPLv2 or later
3
  * Plugin Name: MW WP Form
4
  * Plugin URI: http://plugins.2inc.org/mw-wp-form/
5
  * Description: MW WP Form is shortcode base contact form plugin. This plugin have many feature. For example you can use many validation rules, contact data saving, and chart aggregation using saved contact data.
6
+ * Version: 3.2.1
7
  * Author: Takashi Kitajima
8
  * Author URI: http://2inc.org
9
  * Created : September 25, 2012
10
+ * Modified: May 4, 2017
11
  * Text Domain: mw-wp-form
12
  * Domain Path: /languages/
13
  * License: GPLv2 or later
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.amazon.co.jp/registry/wishlist/39ANKRNSTNW40
4
  Tags: plugin, form, confirm, preview, shortcode, mail, chart, graph, html, contact form, form creation, form creator, form manager, form builder, custom form
5
  Requires at least: 4.0
6
  Tested up to: 4.7.4
7
- Stable tag: 3.2.0
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -80,6 +80,9 @@ Do you have questions or issues with MW WP Form? Use these support channels appr
80
 
81
  == Changelog ==
82
 
 
 
 
83
  = 3.2.0 =
84
  * Added : Added process of mail sending error. When failed mail sending, displayed mail sending error page.
85
  * Added : Added filter hook mwform_is_mail_sended
4
  Tags: plugin, form, confirm, preview, shortcode, mail, chart, graph, html, contact form, form creation, form creator, form manager, form builder, custom form
5
  Requires at least: 4.0
6
  Tested up to: 4.7.4
7
+ Stable tag: 3.2.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
80
 
81
  == Changelog ==
82
 
83
+ = 3.2.1 =
84
+ * Bugfix : Fixed a bug that displayed send error page when admin mail address is `false`.
85
+
86
  = 3.2.0 =
87
  * Added : Added process of mail sending error. When failed mail sending, displayed mail sending error page.
88
  * Added : Added filter hook mwform_is_mail_sended