From 444d6eb9fdd0f8fdc9febadce096aab1becc4964 Mon Sep 17 00:00:00 2001 From: Anastasia Smolyakova Date: Mon, 5 Feb 2024 20:50:43 +0300 Subject: [PATCH] fix route name --- public/index.php | 6 +++--- templates/urls/show.phtml | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/public/index.php b/public/index.php index 5f2c7c8..aa4f987 100644 --- a/public/index.php +++ b/public/index.php @@ -194,8 +194,8 @@ $document = new Document($resBody); $h1 = Str::limit(optional($document->first('h1'))->text() ?? '', 250, '(...)'); $title = Str::limit(optional($document->first('title'))->text() ?? '', 250, '(...)'); - $description = Str::limit(optional($document->first('meta[name="description"]')) - ->getAttribute('content') ?? '', 250, '(...)'); + $description = optional($document->first('meta[name="description"]')) + ->getAttribute('content') ?? ''; } $newCheckQuery = 'INSERT INTO url_checks( @@ -224,6 +224,6 @@ ]); return $response->withRedirect($this->get('router')->urlFor('urls.show', ['id' => $urlId])); -})->setName('urls.check'); +})->setName('urls.checks.store'); $app->run(); diff --git a/templates/urls/show.phtml b/templates/urls/show.phtml index 366f76c..7389345 100644 --- a/templates/urls/show.phtml +++ b/templates/urls/show.phtml @@ -18,7 +18,8 @@

Проверки

-
+