diff --git a/modules/profile/profile.module b/modules/profile/profile.module
index 141c094..e076be6 100644
--- a/modules/profile/profile.module
+++ b/modules/profile/profile.module
@@ -253,8 +253,8 @@ function profile_view_field($user, $field) {
   $browse = user_access('access user profiles')
          && (user_access('administer users') || $field->visibility != PROFILE_PRIVATE)
          && !empty($field->page);
-
-  if (isset($user->{$field->name}) && $value = $user->{$field->name}) {
+  $value = $user->{$field->name};
+  if (isset($user->{$field->name}) && isset($value)) {
     switch ($field->type) {
       case 'textarea':
         return check_markup($value);
@@ -284,7 +284,8 @@ function profile_view_field($user, $field) {
         $values = split("[,\n\r]", $value);
         $fields = array();
         foreach ($values as $value) {
-          if ($value = trim($value)) {
+          $value = trim($value);
+          if (isset($value)) {
             $fields[] = $browse ? l($value, 'profile/'. $field->name .'/'. $value) : check_plain($value);
           }
         }
@@ -307,7 +308,8 @@ function profile_view_profile(&$user) {
 
   $fields = array();
   while ($field = db_fetch_object($result)) {
-    if ($value = profile_view_field($user, $field)) {
+    $value = profile_view_field($user, $field);
+    if (isset($value)) {
       $title = ($field->type != 'checkbox') ? check_plain($field->title) : NULL;
 
       // Create a single fieldset for each category.
@@ -394,7 +396,8 @@ function profile_form_profile($edit, $user, $category, $register = FALSE) {
         $options = $field->required ? array() : array('--');
         $lines = split("[\n\r]", $field->options);
         foreach ($lines as $line) {
-          if ($line = trim($line)) {
+          $line = trim($line);
+          if (isset($line) && $line != '') {
             $options[$line] = $line;
           }
         }
@@ -489,7 +492,7 @@ function template_preprocess_profile_block(&$variables) {
   $variables['profile'] = array();
   // Supply filtered version of $fields that have values.
   foreach ($variables['fields'] as $field) {
-    if ($field->value) {
+    if (isset($field->value)) {
       $variables['profile'][$field->name]->title = check_plain($field->title);
       $variables['profile'][$field->name]->value = $field->value;
       $variables['profile'][$field->name]->type = $field->type;
@@ -514,7 +517,7 @@ function template_preprocess_profile_listing(&$variables) {
   $variables['profile'] = array();
   // Supply filtered version of $fields that have values.
   foreach ($variables['fields'] as $field) {
-    if ($field->value) {
+    if (isset($field->value)) {
       $variables['profile'][$field->name]->title = $field->title;
       $variables['profile'][$field->name]->value = $field->value;
       $variables['profile'][$field->name]->type = $field->type;
@@ -533,7 +536,8 @@ function template_preprocess_profile_listing(&$variables) {
  */
 function template_preprocess_profile_wrapper(&$variables) {
   $variables['current_field'] = '';
-  if ($field = arg(1)) {
+  $field_from_arg = arg(1);
+  if (isset($field_from_arg)) {
     $variables['current_field'] = $field;
     // Supply an alternate template suggestion based on the browsable field.
     $variables['template_files'][] = 'profile-wrapper-'. $field;
