From 7ce4af03b70d36e30fe90f3dc0d03b5d87cb4d3c Mon Sep 17 00:00:00 2001 From: nikitasinelnikov Date: Fri, 29 Mar 2019 17:43:51 +0200 Subject: [PATCH] - fixed locate template in default plugin folder; --- includes/admin/core/class-admin-metabox.php | 5 +++++ includes/core/class-external-integrations.php | 5 ++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/includes/admin/core/class-admin-metabox.php b/includes/admin/core/class-admin-metabox.php index 920c574a..35052966 100644 --- a/includes/admin/core/class-admin-metabox.php +++ b/includes/admin/core/class-admin-metabox.php @@ -40,6 +40,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Metabox' ) ) { add_filter( 'um_builtin_validation_types_continue_loop', array( &$this, 'validation_types_continue_loop' ), 1, 4 ); add_filter( 'um_restrict_content_hide_metabox', array( &$this, 'hide_metabox_restrict_content_shop' ), 10, 1 ); + + + /** + * @todo remove these options + */ add_filter( 'um_admin_access_settings_fields', array( &$this, 'wpml_post_options' ), 10, 2 ); } diff --git a/includes/core/class-external-integrations.php b/includes/core/class-external-integrations.php index 46f98978..30b79da7 100644 --- a/includes/core/class-external-integrations.php +++ b/includes/core/class-external-integrations.php @@ -371,8 +371,7 @@ if ( ! class_exists( 'um\core\External_Integrations' ) ) { $language_codes = $this->get_languages_codes(); $lang = ''; - if ( $language_codes['default'] != $language_codes['current'] /*&& - UM()->config()->email_notifications[ $template_name ]['recipient'] != 'admin'*/ ) { + if ( $language_codes['default'] != $language_codes['current'] ) { $lang = $language_codes['current'] . '/'; } @@ -385,7 +384,7 @@ if ( ! class_exists( 'um\core\External_Integrations' ) ) { //if there isn't template at theme folder get template file from plugin dir if ( ! $template ) { $path = ! empty( UM()->mail()->path_by_slug[ $template_name ] ) ? UM()->mail()->path_by_slug[ $template_name ] : um_path . 'templates/email'; - $template = trailingslashit( $path ) . $lang . $template_name . '.php'; + $template = trailingslashit( $path ) . $template_name . '.php'; } return $template;