PluginProbe
WPGraphQL / 2.22.3
WPGraphQL v2.22.3
2.22.3 2.22.2 2.22.1 2.22.0 2.21.1 2.21.0 2.20.0 2.19.0 2.18.0 2.17.0 2.16.0 2.15.1 2.15.0 2.14.1 2.14.0 2.13.0 2.2.0 2.3.0 2.3.3 2.3.6 2.3.8 2.5.0 2.5.1 2.5.2 2.5.3 All 177 releases
wp-graphql / activation.php

activation.php in WPGraphQL 2.22.3, at activation.php

22 lines 447 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Activation routines for WPGraphQL.
4 *
5 * @package WPGraphQL
6 */
7
8 // Exit if accessed directly.
9 if ( ! defined( 'ABSPATH' ) ) {
10 exit;
11 }
12
13 /**
14 * Runs when WPGraphQL is activated
15 */
16 function graphql_activation_callback(): void {
17 do_action( 'graphql_activate' );
18
19 // phpcs:ignore WordPressVIPMinimum.Functions.RestrictedFunctions.flush_rewrite_rules_flush_rewrite_rules -- Expose the graphql endpoint.
20 flush_rewrite_rules( true );
21 }
22