Skip to content

Commit

Permalink
fix(parser): tag type correction
Browse files Browse the repository at this point in the history
  • Loading branch information
RunDevelopment authored and hosseinmd committed Feb 1, 2021
1 parent 9bb4ec6 commit 6dc67c7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ export const getParser = (parser: any) =>
}) => {
/** When space between tag and type missed */
const tagSticksToType = tag.indexOf("{");
if (tagSticksToType !== -1) {
type = tag.slice(tagSticksToType + 1, tag.indexOf("}"));
if (tagSticksToType !== -1 && tag[tag.length - 1] === "}") {
type = tag.slice(tagSticksToType + 1, -1);
tag = tag.slice(0, tagSticksToType);
}

Expand Down

0 comments on commit 6dc67c7

Please sign in to comment.