Make WordPress Core

Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#20063 closed defect (bug) (fixed)

Incorrect PHPDoc for get_current_screen

Reported by: markauk's profile markauk Owned by: nacin's profile nacin
Milestone: 3.4 Priority: normal
Severity: minor Version: 3.3.1
Component: Inline Docs Keywords:
Focuses: Cc:

Description

The PHPDoc documentation for get_current_screen doesn't properly define the type of object which is returned. It should be:-

* @return object WP_Screen

Patch attached.

Obviously this doesn't make any difference to the running of the code, but will make life easier for anyone with IDE's which parse PHPDoc comments.

Attachments (1)

patch.diff (314 bytes) - added by markauk 13 years ago.

Download all attachments as: .zip

Change History (7)

#1 follow-up: @duck_
13 years ago

Since we can name the specific class it could be:

@return WP_Screen Current screen object

@markauk
13 years ago

#2 in reply to: ↑ 1 @markauk
13 years ago

Yes! I was being unnecessarily frugal with words...

Patch updated.

#3 @nacin
13 years ago

The point was that you can omit 'object' and simply use the actual object WP_Screen as the type designator.

#4 @nacin
13 years ago

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

In [19942]:

Use class name for @return. props markuak, fixes #20063.

#5 @SergeyBiryukov
13 years ago

  • Milestone changed from Awaiting Review to 3.4

#6 @SergeyBiryukov
13 years ago

  • Component changed from General to Inline Docs
Note: See TracTickets for help on using tickets.