diff --git a/avatar_selection.module b/avatar_selection.module index 2cbf392..cac11ac 100644 --- a/avatar_selection.module +++ b/avatar_selection.module @@ -157,7 +157,7 @@ function avatar_selection_form_user_register_alter(&$form, $form_state, $form_id $anon_user = drupal_anonymous_user(); // See if user has access to avatars. - $disable_upload = variable_get('avatar_selection_disable_user_upload', 0) & !user_access('upload avatar in profile'); + $disable_upload = variable_get('avatar_selection_disable_user_upload', 0) || !user_access('upload avatar in profile'); if (!user_access('access avatars')) { // If uploads also disabled, remove the field altogether. if ($disable_upload) { @@ -236,7 +236,7 @@ function avatar_selection_form_user_profile_form_alter(&$form, $form_state, $for $user = user_load(array('uid' => $form['#uid'])); // See if user has access to avatars. - $disable_upload = variable_get('avatar_selection_disable_user_upload', 0) & !user_access('upload avatar in profile'); + $disable_upload = variable_get('avatar_selection_disable_user_upload', 0) || !user_access('upload avatar in profile'); if (!user_access('access avatars')) { // If uploads also disabled, remove the field altogether. if ($disable_upload) {