Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: rest_pre_insert_{$this->taxonomy}

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
850            *
851            *  - `rest_pre_insert_category`
852            *  - `rest_pre_insert_post_tag`
853            *
854            * @since 4.7.0
855            *
856            * @param object          $prepared_term Term object.
857            * @param WP_REST_Request $request       Request object.
858            */
859           return apply_filters( "rest_pre_insert_{$this->taxonomy}", $prepared_term, $request );
860      }
861
862      /**
863       * Prepares a single term output for response.
864       *
865       * @since 4.7.0
866       *
867       * @param WP_Term         $item    Term object.
868       * @param WP_REST_Request $request Request object.