Opened 12 years ago
Closed 12 years ago
#2359 closed defect (bug) (fixed)
Using bbp_get_displayed_user_field() when there is no displayed user causes debug notices
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.4 | Priority: | normal |
Severity: | normal | Version: | 2.1 |
Component: | Tools - Code Improvements | Keywords: | |
Cc: |
Description
If you call bbp_get_displayed_user_field() when not viewing a user, or if you attempt to get a field that does not exist, you'll be greeted with debug notices because the object being referenced is a stdObject, not a WP_User object.
If we use WP_User objects, we'll inherit the magic methods for free, and avoid these problems completely.
Worth noting here that we can do the same for the 4 main query loops.
Change History (1)
Note: See
TracTickets for help on using
tickets.
In 4996: