From b1a8f6e54710b65d93ed7e7dac70bafb1b83fbb8 Mon Sep 17 00:00:00 2001
From: Andy Postnikov <andypost@ya.ru>
Date: Thu, 3 Mar 2011 03:41:57 +0700
Subject: [PATCH] #1079064 by joelstein, me: Fix PHP notice

---
 imagecache_profiles.module |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/imagecache_profiles.module b/imagecache_profiles.module
index 9649ef0..6d50ad4 100644
--- a/imagecache_profiles.module
+++ b/imagecache_profiles.module
@@ -42,7 +42,7 @@ function imagecache_profiles_preprocess_user_picture(&$variables) {
       $picture = variable_get('user_picture_default', '');
     }
 
-    if (isset($picture)) {
+    if (isset($picture) && !empty($preset)) {
       $alt = t("@user's picture", array('@user' => $account->name ? $account->name : variable_get('anonymous', t('Anonymous'))));
       $preset = is_numeric($preset) ? imagecache_preset($preset) : imagecache_preset_by_name($preset);
       if (empty($preset)) {
-- 
1.7.2.3

