mirror of
https://github.com/theoleuthardt/werkzeugkiste.git
synced 2026-06-13 09:37:53 +00:00
fix: prettier formating
This commit is contained in:
parent
544ebaa7cf
commit
7b4ef9c70b
13 changed files with 172 additions and 154 deletions
|
|
@ -20,7 +20,9 @@ export async function regexTest(app: FastifyInstance) {
|
|||
|
||||
// Überprüfe, ob die Felder regex und test vorhanden sind
|
||||
if (!data.regex || !data.test) {
|
||||
return reply.status(400).send({ error: "Regex or test string missing!" });
|
||||
return reply
|
||||
.status(400)
|
||||
.send({ error: "Regex or test string missing!" });
|
||||
}
|
||||
|
||||
// Versuche, den regulären Ausdruck zu erstellen
|
||||
|
|
@ -28,7 +30,9 @@ export async function regexTest(app: FastifyInstance) {
|
|||
try {
|
||||
regexPattern = new RegExp(data.regex);
|
||||
} catch (e) {
|
||||
return reply.status(400).send({ error: "Invalid regular expression!" });
|
||||
return reply
|
||||
.status(400)
|
||||
.send({ error: "Invalid regular expression!" });
|
||||
}
|
||||
|
||||
// Teste den Eingabestring gegen das Regex
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue