Hooks::maybe_toggle_hooks_for_rest( string $slug, array $params, WP_REST_Request $request )
Maybe toggles the hooks for a widget class on a rest request.
Contents
Parameters
- $slug
-
(string) (Required) The current view Slug.
- $params
-
(array) (Required) Params so far that will be used to build this view.
- $request
-
(WP_REST_Request) (Required) The rest request that generated this call.
Source
File: src/Tribe/Views/V2/Widgets/Hooks.php
public function maybe_toggle_hooks_for_rest( $slug, $params, \WP_REST_Request $request ) {
Widget_Shortcode::maybe_toggle_hooks_for_rest( $slug, $params, $request );
}
Changelog
| Version | Description |
|---|---|
| 6.1.4 | Test the slug and only trigger for widgets that use the Widget_Shortcode trait (month and week). |
| 5.5.0 | Introduced. |