Make WordPress Core

Opened 13 years ago

Closed 13 years ago

#21041 closed enhancement (fixed)

Remove variable store in get_the_excerpt

Reported by: niallkennedy's profile niallkennedy Owned by: markjaquith's profile markjaquith
Milestone: 3.5 Priority: normal
Severity: trivial Version:
Component: Template Keywords: has-patch commit
Focuses: Cc:

Description

It looks like get_the_excerpt() either returns a password protected message or post->post_excerpt passed through a filter.

Storing excerpt in a variable should not be necessary; pass directly instead.

Attachments (1)

post-template.diff (667 bytes) - added by niallkennedy 13 years ago.
return string without first storing it in a variable

Download all attachments as: .zip

Change History (3)

@niallkennedy
13 years ago

return string without first storing it in a variable

#1 @nacin
13 years ago

  • Keywords commit added
  • Milestone changed from Awaiting Review to 3.5
  • Severity changed from minor to trivial

#2 @markjaquith
13 years ago

  • Owner set to markjaquith
  • Resolution set to fixed
  • Status changed from new to closed

In [21159]:

Do not store post_excerpt in a temporary variable when we can just return it directly. props niallkennedy. fixes #21041

Note: See TracTickets for help on using tickets.