Problem/Motivation

Follow-up to #3072305-45: Notice: Undefined index: #item in user_user_view_alter()
It is used in system module (indirect dependency on user) via \Drupal\system\Form\ThemeSettingsForm::buildForm()
Function used only once in contrib.

Proposed resolution

- deprecate user_picture_enabled()
- Inline the check in the two places it's used.

Remaining tasks

User interface changes

N/A

API changes

N/A

Data model changes

N/A

Release notes snippet

N/A

Issue fork drupal-3151555

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

andypost created an issue. See original summary.

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 10.1.x-dev » 11.x-dev

Drupal core is moving towards using a “main” branch. As an interim step, a new 11.x branch has been opened, as Drupal.org infrastructure cannot currently fully support a branch named main. New developments and disruptive changes should now be targeted for the 11.x branch, which currently accepts only minor-version allowed changes. For more information, see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.

nicxvan made their first commit to this issue’s fork.

nicxvan’s picture

Issue summary: View changes
nicxvan’s picture

Status: Active » Needs review

There is only one usage in contrib, I think we can just inline this in the two core calls to it.

I don't think we need to complicate this too much.

nicxvan’s picture

Title: Deprecate user_picture_enabled() reconsider user picture field » Deprecate user_picture_enabled()
smustgrave’s picture

Status: Needs review » Reviewed & tested by the community

With so little usage almost wonder if it could be removed in 12? But this looks good will let committer decide if it's 12 or 13.

  • catch committed 128ee3cc on 11.x
    task: #3151555 Deprecate user_picture_enabled()
    
    By: andypost
    By:...

  • catch committed d7ba4a8b on main
    task: #3151555 Deprecate user_picture_enabled()
    
    By: andypost
    By:...
catch’s picture

Version: main » 11.x-dev
Status: Reviewed & tested by the community » Fixed

I think we could get away with deprecating for removal in Drupal 12, but also for procedural functions the 13.x removal is going to be git rm foo.module and there's not really any bc layer to maintain either, so 13.x seems OK too.

Committed/pushed to main and 11.x, thanks!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.