Skip to content

Commit

Permalink
ZETA-6955: Fix unit test.
Browse files Browse the repository at this point in the history
  • Loading branch information
CharlieGreenman committed Oct 25, 2023
1 parent 075986b commit 491e4f9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rz/angular/insert-into-html-tag/insert-into-html-tag.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import { parseHtml } from '../morph-angular-html';
import { EditHtmlFile } from '../interfaces/edit-html.interface';

// will insert code into an html block
export async function insertIntoHtmlTag(editFile: EditHtmlFile, astNode: any): Promise<any> {
export function insertIntoHtmlTag(editFile: EditHtmlFile, astNode: any): Promise<any> {
let counter = 0;
const codeToAddTree = await parseHtml(editFile.codeBlock as string);
const codeToAddTree = parseHtml(editFile.codeBlock as string);
astNode.rootNodes.forEach((node: any) => {
visit(node, {type: 'element', name: editFile.tagNameToInsertInto}, (node: any, index) => {
if(!editFile.className || editFile.className === '' || node.attrs.find((attr: any) => attr.value === editFile.className)) {
Expand Down

0 comments on commit 491e4f9

Please sign in to comment.