From 7c8ad4d97329ef220e150e16d21ef85eb5240502 Mon Sep 17 00:00:00 2001 From: sainty0 Date: Fri, 6 Aug 2021 20:17:15 +1000 Subject: [PATCH] Fixed issues with 5.8 update of php --- app/controller/class-ms-controller-plugin.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/app/controller/class-ms-controller-plugin.php b/app/controller/class-ms-controller-plugin.php index 60ad9daa..0a69a5ee 100644 --- a/app/controller/class-ms-controller-plugin.php +++ b/app/controller/class-ms-controller-plugin.php @@ -961,9 +961,10 @@ public function custom_single_template( $default_template ) { * * @return string The custom template path. */ + public function custom_page_template( $default_template ) { $template = ''; - + // Checks for invoice single template. if ( $type = MS_Model_Pages::is_membership_page() ) { $membership_id = apply_filters( @@ -972,26 +973,25 @@ public function custom_page_template( $default_template ) { true, true ); - + if ( $membership_id ) { $template = get_query_template( 'm2', - 'm2-' . $type . '-' . $membership_id . '.php' + array('m2-' . $type . '-' . $membership_id . '.php') ); } - + if ( ! $template ) { $template = get_query_template( 'm2', - 'm2-' . $type . '.php' + array('m2-' . $type . '.php') ); } } - + if ( ! $template ) { $template = $default_template; } - return $template; }