File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed
Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -8383,6 +8383,10 @@ public function load_pod( $params, $strict = false ) {
83838383 $ params = get_object_vars ( (object ) $ params );
83848384 }
83858385
8386+ if ( ! empty ( $ params ['name ' ] ) && $ params ['name ' ] instanceof Pod ) {
8387+ return $ params ['name ' ];
8388+ }
8389+
83868390 if ( empty ( $ params ) ) {
83878391 return false ;
83888392 }
@@ -8586,6 +8590,14 @@ public function load_field( $params, $strict = false ) {
85868590 $ params = get_object_vars ( (object ) $ params );
85878591 }
85888592
8593+ if ( ! empty ( $ params ['name ' ] ) && $ params ['name ' ] instanceof Field ) {
8594+ return $ params ['name ' ];
8595+ }
8596+
8597+ if ( empty ( $ params ) ) {
8598+ return false ;
8599+ }
8600+
85898601 // Check if we need to bypass cache automatically.
85908602 if ( ! isset ( $ params ['bypass_cache ' ] ) ) {
85918603 $ api_cache = pods_api_cache ();
@@ -8940,6 +8952,14 @@ public function load_group( $params, $strict = false ) {
89408952 $ params = get_object_vars ( (object ) $ params );
89418953 }
89428954
8955+ if ( ! empty ( $ params ['name ' ] ) && $ params ['name ' ] instanceof Group ) {
8956+ return $ params ['name ' ];
8957+ }
8958+
8959+ if ( empty ( $ params ) ) {
8960+ return false ;
8961+ }
8962+
89438963 // Check if we need to bypass cache automatically.
89448964 if ( ! isset ( $ params ['bypass_cache ' ] ) ) {
89458965 $ api_cache = pods_api_cache ();
You can’t perform that action at this time.
0 commit comments