Version Description
- Fix get_post_metadata hooked only preview #43 (by @wireframeslayout)
Download this release
Release Info
Developer | inc2734 |
Plugin | Smart Custom Fields |
Version | 2.2.3 |
Comparing to | |
See all releases |
Code changes from version 2.2.2 to 2.2.3
- classes/models/class.revisions.php +6 -2
- readme.txt +5 -2
- smart-custom-fields.php +2 -2
classes/models/class.revisions.php
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
* Smart_Custom_Fields_Revisions
|
4 |
-
* Version : 1.1.
|
5 |
* Author : inc2734
|
6 |
* Created : September 23, 2014
|
7 |
-
* Modified :
|
8 |
* License : GPLv2 or later
|
9 |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
*/
|
@@ -84,6 +84,10 @@ class Smart_Custom_Fields_Revisions {
|
|
84 |
* @return mixed $value
|
85 |
*/
|
86 |
public function get_post_metadata( $value, $post_id, $meta_key, $single ) {
|
|
|
|
|
|
|
|
|
87 |
if ( is_null( SCF::get_field( get_post( $post_id ), $meta_key ) ) ) {
|
88 |
return $value;
|
89 |
}
|
1 |
<?php
|
2 |
/**
|
3 |
* Smart_Custom_Fields_Revisions
|
4 |
+
* Version : 1.1.6
|
5 |
* Author : inc2734
|
6 |
* Created : September 23, 2014
|
7 |
+
* Modified : August 24, 2016
|
8 |
* License : GPLv2 or later
|
9 |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
*/
|
84 |
* @return mixed $value
|
85 |
*/
|
86 |
public function get_post_metadata( $value, $post_id, $meta_key, $single ) {
|
87 |
+
if ( ! is_preview() ) {
|
88 |
+
return $value;
|
89 |
+
}
|
90 |
+
|
91 |
if ( is_null( SCF::get_field( get_post( $post_id ), $meta_key ) ) ) {
|
92 |
return $value;
|
93 |
}
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: inc2734, toro_unit, mimosafa, hideokamoto, hisako-isaka, kurudrive
|
|
3 |
Donate link: http://www.amazon.co.jp/registry/wishlist/39ANKRNSTNW40
|
4 |
Tags: plugin, custom field, custom, field, meta, meta field, repeat, repeatable
|
5 |
Requires at least: 3.9
|
6 |
-
Tested up to: 4.
|
7 |
-
Stable tag: 2.2.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -125,6 +125,9 @@ You can send your own language pack to me.
|
|
125 |
|
126 |
== Changelog ==
|
127 |
|
|
|
|
|
|
|
128 |
= 2.2.2 =
|
129 |
* Fix #37 #38
|
130 |
|
3 |
Donate link: http://www.amazon.co.jp/registry/wishlist/39ANKRNSTNW40
|
4 |
Tags: plugin, custom field, custom, field, meta, meta field, repeat, repeatable
|
5 |
Requires at least: 3.9
|
6 |
+
Tested up to: 4.6.0
|
7 |
+
Stable tag: 2.2.3
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
125 |
|
126 |
== Changelog ==
|
127 |
|
128 |
+
= 2.2.3 =
|
129 |
+
* Fix get_post_metadata hooked only preview #43 (by [@wireframeslayout](https://github.com/wireframeslayout))
|
130 |
+
|
131 |
= 2.2.2 =
|
132 |
* Fix #37 #38
|
133 |
|
smart-custom-fields.php
CHANGED
@@ -3,11 +3,11 @@
|
|
3 |
* Plugin name: Smart Custom Fields
|
4 |
* Plugin URI: https://github.com/inc2734/smart-custom-fields/
|
5 |
* Description: Smart Custom Fields is a simple plugin that management custom fields.
|
6 |
-
* Version: 2.2.
|
7 |
* Author: inc2734
|
8 |
* Author URI: http://2inc.org
|
9 |
* Created: October 9, 2014
|
10 |
-
* Modified:
|
11 |
* Text Domain: smart-custom-fields
|
12 |
* Domain Path: /languages
|
13 |
* License: GPLv2 or later
|
3 |
* Plugin name: Smart Custom Fields
|
4 |
* Plugin URI: https://github.com/inc2734/smart-custom-fields/
|
5 |
* Description: Smart Custom Fields is a simple plugin that management custom fields.
|
6 |
+
* Version: 2.2.3
|
7 |
* Author: inc2734
|
8 |
* Author URI: http://2inc.org
|
9 |
* Created: October 9, 2014
|
10 |
+
* Modified: August 24, 2016
|
11 |
* Text Domain: smart-custom-fields
|
12 |
* Domain Path: /languages
|
13 |
* License: GPLv2 or later
|