Skip to content

Commit

Permalink
sample fix (#51)
Browse files Browse the repository at this point in the history
  • Loading branch information
rambleraptor authored Nov 8, 2024
1 parent 2fe8437 commit 75b3b94
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/utils/sample.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function sampleYaml(code: string, path: string): string {

let traversal = yaml_code;

for (let i = 0; i < segments.length - 1; i++) {
for (let i = 0; i < segments.length; i++) {
if (segments[i] != "$") {
current[segments[i]] = {};
current = current[segments[i]];
Expand Down Expand Up @@ -125,4 +125,4 @@ function sampleProto(code: string, token1: string, token2: string) {
throw new Error("Bad output");
}

export default sampleCode;
export default sampleCode;

0 comments on commit 75b3b94

Please sign in to comment.