@@ 209-225 (lines=17) @@ | ||
206 | * |
|
207 | * @since 2.0 |
|
208 | */ |
|
209 | public function clear_cache ( $data, $pod = null, $id = null, $groups = null, $post = null ) { |
|
210 | $old_post = $id; |
|
211 | ||
212 | if ( !is_object( $id ) ) |
|
213 | $old_post = null; |
|
214 | ||
215 | if ( is_object( $post ) && $this->object_type != $post->post_type ) |
|
216 | return; |
|
217 | ||
218 | if ( !is_array( $data ) && 0 < $data ) { |
|
219 | $post = $data; |
|
220 | $post = get_post( $post ); |
|
221 | } |
|
222 | ||
223 | if ( $this->object_type == $post->object_type ) |
|
224 | pods_transient_clear( 'pods_object_helpers' ); |
|
225 | } |
|
226 | ||
227 | /** |
|
228 | * Change post title placeholder text |
@@ 252-268 (lines=17) @@ | ||
249 | * |
|
250 | * @since 2.0 |
|
251 | */ |
|
252 | public function clear_cache ( $data, $pod = null, $id = null, $groups = null, $post = null ) { |
|
253 | $old_post = $id; |
|
254 | ||
255 | if ( !is_object( $id ) ) |
|
256 | $old_post = null; |
|
257 | ||
258 | if ( is_object( $post ) && $this->object_type != $post->post_type ) |
|
259 | return; |
|
260 | ||
261 | if ( !is_array( $data ) && 0 < $data ) { |
|
262 | $post = $data; |
|
263 | $post = get_post( $post ); |
|
264 | } |
|
265 | ||
266 | if ( $this->object_type == $post->object_type ) |
|
267 | pods_transient_clear( 'pods_object_templates' ); |
|
268 | } |
|
269 | ||
270 | /** |
|
271 | * Change post title placeholder text |