Now that dependency injection has made it into core: #1497230: Use Dependency Injection to handle object definitions we should reduce the number of things we put into the $GLOBALS array, starting with things that touch the site's language .

On line 952 and 1019 of comment.module we are using $GLOBALS['lanaguage_content]->langcode . We should modify this to use the DI container.

CommentFileSizeAuthor
#7 1539608.patch1017 bytesRobLoach
#2 1539608_2_comment_di.patch1017 bytescosmicdreams
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

sun’s picture

cosmicdreams’s picture

Status: Active » Needs review
FileSize
1017 bytes

First Try

cosmicdreams’s picture

Assigned: Unassigned » cosmicdreams

Assigning to me so I can show these to folks easier

RobLoach’s picture

Priority: Normal » Minor
Status: Needs review » Reviewed & tested by the community

Another easy one :-) .

Dries’s picture

Mmm, doesn't seem to apply anymore. Asking for a re-test.

Dries’s picture

#2: 1539608_2_comment_di.patch queued for re-testing.

RobLoach’s picture

Status: Reviewed & tested by the community » Needs review
FileSize
1017 bytes

Re-rolled.

cosmicdreams’s picture

Status: Needs review » Reviewed & tested by the community

still simple, short and sweet.

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Great. Committed to 8.x. Thanks!

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