Skip to content

Commit

Permalink
fix(app/Generators): remove unnecessary dump() calls
Browse files Browse the repository at this point in the history
- Remove dump() call before matching the output
- Remove dump() call after replacing matches
  • Loading branch information
[email protected] committed Oct 15, 2024
1 parent d5b4405 commit 8f86854
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions app/Generators/GithubCopilotCliGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,11 @@ public function generate(string $prompt): string
})->getOutput();

return (string) str($output)
->dump()
->match('/\{.*\}/s')
->dump()
// ->replaceMatches('/[[:cntrl:]]/mu', '')
->replace(
["\\'", PHP_EOL],
["'", '']
)
->dump()
// ->replaceMatches('/[[:cntrl:]]/mu', '')
->dump();
);
}
}

0 comments on commit 8f86854

Please sign in to comment.