From f20b971580f0fa7bce9d6256d5af64b57b8cfb77 Mon Sep 17 00:00:00 2001 From: Steve Sutton Date: Mon, 11 Mar 2019 13:42:30 -0400 Subject: [PATCH] Add call for requiring any routes.php file found in plugins setup folder This will be for adding routes for the REST API. --- controllers/front.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/controllers/front.php b/controllers/front.php index 5d6aa9ca..23a7bfd4 100644 --- a/controllers/front.php +++ b/controllers/front.php @@ -83,6 +83,11 @@ class glmMembersFront extends GlmPluginSupport require_once $hooksFile; } + $routesFile = GLM_MEMBERS_WORDPRESS_PLUGIN_PATH . $a['slug'] . '/setup/routes.php'; + if ( is_file( $routesFile ) ) { + require_once $routesFile; + } + // Check for a commonHooks.php file - Maps various add_filters to apply_filters for the add-on $commonFile = GLM_MEMBERS_WORDPRESS_PLUGIN_PATH.$a['slug'].'/setup/commonHooks.php'; if (is_file($commonFile)) { -- 2.17.1