Skip to content

Commit

Permalink
feat: Never return spaces for too deep levels
Browse files Browse the repository at this point in the history
  • Loading branch information
fwh1990 committed Sep 17, 2020
1 parent 850e914 commit ce6fad2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/parse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ const preDefinedSpaces = [
];

const addSpace = (length: number) => {
return preDefinedSpaces[length / 2];
return preDefinedSpaces[length / 2] || '';
}

const capitalize = (value: string) => {
Expand Down

0 comments on commit ce6fad2

Please sign in to comment.