Remove usage of hardcoded mailpoet_email
string from the JS package
MAILPOET-6430
This commit is contained in:
committed by
Oluwaseun Olorunsola
parent
9a2502826f
commit
a49b978050
@ -16,6 +16,7 @@ import {
|
||||
storeName,
|
||||
TemplateCategory,
|
||||
TemplatePreview,
|
||||
editorCurrentPostType,
|
||||
} from '../../store';
|
||||
import { TemplateList } from './template-list';
|
||||
import { TemplateCategoriesListSidebar } from './template-categories-list-sidebar';
|
||||
@ -94,7 +95,7 @@ export function SelectTemplateModal( {
|
||||
const hasTemplates = templates?.length > 0;
|
||||
|
||||
const handleTemplateSelection = ( template: TemplatePreview ) => {
|
||||
const templateIsPostContent = template.type === 'mailpoet_email';
|
||||
const templateIsPostContent = template.type === editorCurrentPostType;
|
||||
|
||||
const postContent = template.template as unknown as EmailEditorPostType;
|
||||
|
||||
|
Reference in New Issue
Block a user