Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#15094 closed defect (bug) (fixed)

Redundant function_exists() check in wp_nav_menu()

Reported by: scribu Owned by:
Priority: normal Milestone: 3.1
Component: Menus Version:
Severity: minor Keywords:
Cc:

Description

When the 'fallback_cb' arg is checked, it calls function_exists() right before is_callable(), which not only is redundant, but also prevents passing a class method as a callback.

Attachments (1)

15094.diff (787 bytes) - added by scribu 3 years ago.

Download all attachments as: .zip

Change History (5)

  • Severity changed from normal to minor

Ok, it doesn't prevent passing a class method, since it's ORed, but it's still redundant.

scribu3 years ago

Related: [15772]

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

(In [15774]) Remove redundant call to function_exists() in wp_nav_menu(). Fixes #15094

Related: [15772]

Note: See TracTickets for help on using tickets.