Migrate email editor templates class to WP Coding Standard
[MAILPOET-6240]
This commit is contained in:
@@ -39,8 +39,8 @@ class Renderer {
|
||||
|
||||
public function render( \WP_Post $post, string $subject, string $preHeader, string $language, $metaRobots = '' ): array {
|
||||
$templateId = 'mailpoet/mailpoet//' . ( get_page_template_slug( $post ) ?: 'email-general' );
|
||||
$template = $this->templates->getBlockTemplate( $templateId );
|
||||
$theme = $this->templates->getBlockTemplateTheme( $templateId, $template->wp_id ); // phpcs:ignore Squiz.NamingConventions.ValidVariableName.MemberNotCamelCaps
|
||||
$template = $this->templates->get_block_template( $templateId );
|
||||
$theme = $this->templates->get_block_template_theme( $templateId, $template->wp_id ); // phpcs:ignore Squiz.NamingConventions.ValidVariableName.MemberNotCamelCaps
|
||||
|
||||
// Set the theme for the template. This is merged with base theme.json and core json before rendering.
|
||||
self::$theme = new WP_Theme_JSON( $theme, 'default' );
|
||||
|
Reference in New Issue
Block a user