Index: content_profile.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/content_profile/Attic/content_profile.module,v
retrieving revision 1.1.2.32
diff -u -p -r1.1.2.32 content_profile.module
--- content_profile.module	7 Jan 2009 10:58:05 -0000	1.1.2.32
+++ content_profile.module	16 Jun 2009 15:59:46 -0000
@@ -394,6 +394,9 @@ function content_profile_nodeapi(&$node,
  * @return If a node exists, the node id, FALSE else.
  */
 function content_profile_profile_exists($node, $uid) {
+  if (!$uid) {
+    return FALSE;
+  }
   $query = "SELECT n.nid AS nid FROM {node} n WHERE n.type = '%s' AND n.uid = %d ";
   if (module_exists('translation') && translation_supported_type($node->type)) {
     $query .= "AND n.language = '%s'";
