check content_object is valid before carrying on

master
Marek Isalski 8 years ago
parent a508cc83b5
commit 93e8ba3935

@ -1,5 +1,5 @@
<tr> <tr>
<td><?php print nl2br( check_plain( $item[ 'name' ] ) ); if ( array_key_exists( 'content_object', $item ) ) { <td><?php print nl2br( check_plain( $item[ 'name' ] ) ); if ( array_key_exists( 'content_object', $item ) && is_array( $item[ 'content_object' ] ) && array_key_exists( 'url', $item[ 'content_object' ] ) ) {
if ( fulcrm_apiv2_url_is_type( $item[ 'content_object' ][ 'url' ], 'eventbooking' ) ) { if ( fulcrm_apiv2_url_is_type( $item[ 'content_object' ][ 'url' ], 'eventbooking' ) ) {
if ( $item[ 'content_object' ][ 'attended' ] ) { if ( $item[ 'content_object' ][ 'attended' ] ) {
print '<br /><strong>Thank you for coming to the event!</strong>'; print '<br /><strong>Thank you for coming to the event!</strong>';

Loading…
Cancel
Save