Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Further logic tweaks on $lookup_built_in

  • Loading branch information...
commit 4a89a26b7b29f6b191840e1cad57956208c3403d 1 parent c6f0581
@sc0ttkclark sc0ttkclark authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 classes/PodsAPI.php
View
6 classes/PodsAPI.php
@@ -904,16 +904,16 @@ public function save_pod ( $params ) {
$lookup_name = $pod[ 'name' ];
- if ( 'post_type' == $pod[ 'type' ] && isset( $built_in[ 'taxonomy' ] ) ) {
+ if ( 'post_type' == $pod[ 'type' ] ) {
$lookup_option = 'built_in_post_types_' . $lookup_name;
$lookup_built_in = 'taxonomy';
}
- elseif ( 'taxonomy' == $pod[ 'type' ] && isset( $built_in[ 'post_type' ] ) ) {
+ elseif ( 'taxonomy' == $pod[ 'type' ] ) {
$lookup_option = 'built_in_taxonomies_' . $lookup_name;
$lookup_built_in = 'post_type';
}
- if ( !empty( $lookup_option ) && !empty( $lookup_built_in ) ) {
+ if ( !empty( $lookup_option ) && !empty( $lookup_built_in ) && isset( $built_in[ $lookup_built_in ] ) && !empty( $built_in[ $lookup_built_in ] ) ) {
foreach ( $built_in[ $lookup_built_in ] as $built_in_object => $val ) {
$search_val = 1 ^ $val;
Please sign in to comment.
Something went wrong with that request. Please try again.