Subtask of #1830588: [META] remove drupal_set_title() and drupal_get_title()

Problem/Motivation

Using procedural drupal_set_title() inside controller class is not encouraged.

Proposed resolution

Replace drupal_set_title() with #title in page return array.

Remaining tasks

Issue patch

User interface changes

Refer parent issue at #1830588: [META] remove drupal_set_title() and drupal_get_title()

API changes

Refer parent issue at #1830588: [META] remove drupal_set_title() and drupal_get_title()

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

InternetDevels’s picture

Status: Active » Needs review
FileSize
1.01 KB
dawehner’s picture

Status: Needs review » Needs work

It seems wrong to just drop the title. Can you explain why you have done this?

disasm’s picture

Status: Needs work » Needs review

I think it's okay to drop the title in this case. It's a test module, and no assertions are being made expecting a title, so why leave it?

dawehner’s picture

I would assume that people use entity_test as a potential example.

dawehner’s picture

Status: Needs review » Reviewed & tested by the community

I will not hold up the patch by that.

catch’s picture

Status: Reviewed & tested by the community » Fixed

If it's in a test module and removing it doesn't break tests, I think it makes sense to remove it. Committed/pushed to 8.x, thanks!

Status: Fixed » Closed (fixed)

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