Skip to:
Content

BuddyPress.org

Opened 5 months ago

Closed 5 months ago

#8334 closed defect (bug) (fixed)

oembed/1.0/embed/activity is missing the required permission_callback

Reported by: imath Owned by: imath
Milestone: 6.2.0 Priority: normal
Severity: normal Version: 2.6.0
Component: Activity Keywords: has-patch
Cc:

Description

Just found this doing_it_wrong notice added in WordPress 5.5. As this route is used to embed activity content into a Post, we simply need to use the __return_true function as the permission callback.

Attachments (1)

8334.patch (760 bytes) - added by imath 5 months ago.

Download all attachments as: .zip

Change History (3)

@imath
5 months ago

#1 @imath
5 months ago

In 12685:

Activity: add a permission_callback to the BP Activity Embed route

Since version 5.5, WordPress is requiring REST routes to have a permission callback. As Activity Embeds are public content and can be seen by any user, we are using the __return_true function as the permission callback for the oembed/1.0/embed/activity route.

See #8334 (trunk)

#2 @imath
5 months ago

  • Owner set to imath
  • Resolution set to fixed
  • Status changed from assigned to closed

In 12686:

Activity: add a permission_callback to the BP Activity Embed route

Since version 5.5, WordPress is requiring REST routes to have a permission callback. As Activity Embeds are public content and can be seen by any user, we are using the __return_true function as the permission callback for the oembed/1.0/embed/activity route.

Fixes #8334 (6.0 branch)

Note: See TracTickets for help on using tickets.