Ian Dunn

Ian Dunn

WordPress Developer

Menu

Skip to content
  • Home
  • About
  • Archives
  • Contact

Tag Archives: register_meta()

Exposing Custom Post Type Meta for Only a Single API Endpoint

I ran into an undocumented and unexpected problem when registering custom post type meta fields for the REST API. register_meta() exposes meta fields in all REST API endpoints, which can lead to privacy leaks. To avoid that, it can be called conditionally.

Continue reading...

Posted on March 30, 2017 by Ian Dunn. Posted in WordPress | Tagged Custom Post Types, Post Meta, Privacy, register_meta(), register_rest_field(), REST API | 2 Comments

Subscribe via Email

Feeds & Profiles

  • RSS
  • WordPress.org
  • GitHub
  • HackerOne
  • LinkedIn