diff --git a/modules/commons/commons_events/commons_events.module b/modules/commons/commons_events/commons_events.module
index a8c7d44..0fb3dc4 100644
--- a/modules/commons/commons_events/commons_events.module
+++ b/modules/commons/commons_events/commons_events.module
@@ -199,8 +199,7 @@ function commons_events_entity_view_alter(&$build, $type) {
     );
     // Don't show the address if the event location is only online.
     $field_location = field_view_field('node', $build['#node'], 'field_location');
-    $field_location = $field_location['#items']['0']['value'];
-    if ($field_location == 'online') {
+    if (isset($field_location['#items']['0']['value']) && $field_location['#items']['0']['value'] == 'online') {
       unset($build['field_address']);
     }
   }
diff --git a/modules/commons/commons_events/includes/commons_events.theme.inc b/modules/commons/commons_events/includes/commons_events.theme.inc
index 0a45515..22a52b8 100644
--- a/modules/commons/commons_events/includes/commons_events.theme.inc
+++ b/modules/commons/commons_events/includes/commons_events.theme.inc
@@ -10,7 +10,7 @@
 function theme_commons_events_attending_event($variables = array()) {
   global $user;
   $event = $variables['event'];
-  $attendee_count = $variables['attendee_count'];
+  $attendee_count = isset($variables['attendee_count']) ? $variables['attendee_count'] : 0;
 
   $registration_type = registration_get_entity_registration_type('node', $event);
   $registration = entity_get_controller('registration')->create(array(
