diff --git a/realname_content_profile.inc b/realname_content_profile.inc
index 5bd02e4..24b0e79 100644
--- a/realname_content_profile.inc
+++ b/realname_content_profile.inc
@@ -45,7 +45,17 @@ function content_profile_load_profile(&$account, $type = NULL) {
 }
 
 function realname_content_profile_get_types() {
-  return content_profile_get_types('names');
+  // Initialize the array of Content Profile types to an empty array
+  $types = array();
+
+  // Iterate through the list of Content Profile type objects
+  foreach (content_profile_get_types() as $type) {
+    // Add the machine name of each Content Profile type object to the array of types
+    $types[] = $type->type;
+  }
+
+  // Return the list of Content Profile types
+  return $types;
 }
 
 function realname_content_profile_get_fields($current, $type) {
