diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2015-01-31 21:24:20 +0100 |
---|---|---|
committer | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2015-01-31 21:24:20 +0100 |
commit | 4cfbd5d893aa51fd5d3b349c2695e9913591041f (patch) | |
tree | c07eb79213d471aa33c49ef4e5819e41cc12f242 /src/Wallabag/CoreBundle/Controller/EntryController.php | |
parent | 1990517b2263a080946853ed697a6d687262ae80 (diff) | |
parent | 7df80cb32ca9b7d0fe452320ddc3563a1e373e2f (diff) | |
download | wallabag-4cfbd5d893aa51fd5d3b349c2695e9913591041f.tar.gz wallabag-4cfbd5d893aa51fd5d3b349c2695e9913591041f.tar.zst wallabag-4cfbd5d893aa51fd5d3b349c2695e9913591041f.zip |
Merge pull request #1037 from j0k3r/refactor-cs
CS
Diffstat (limited to 'src/Wallabag/CoreBundle/Controller/EntryController.php')
-rw-r--r-- | src/Wallabag/CoreBundle/Controller/EntryController.php | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php index 25f18711..377a45ae 100644 --- a/src/Wallabag/CoreBundle/Controller/EntryController.php +++ b/src/Wallabag/CoreBundle/Controller/EntryController.php | |||
@@ -8,14 +8,12 @@ use Symfony\Component\HttpFoundation\Request; | |||
8 | use Wallabag\CoreBundle\Repository; | 8 | use Wallabag\CoreBundle\Repository; |
9 | use Wallabag\CoreBundle\Entity\Entries; | 9 | use Wallabag\CoreBundle\Entity\Entries; |
10 | use Wallabag\CoreBundle\Service\Extractor; | 10 | use Wallabag\CoreBundle\Service\Extractor; |
11 | use Wallabag\CoreBundle\Helper\Tools; | ||
12 | use Wallabag\CoreBundle\Helper\Url; | 11 | use Wallabag\CoreBundle\Helper\Url; |
13 | 12 | ||
14 | class EntryController extends Controller | 13 | class EntryController extends Controller |
15 | { | 14 | { |
16 | |||
17 | /** | 15 | /** |
18 | * @param Request $request | 16 | * @param Request $request |
19 | * @Route("/new", name="new_entry") | 17 | * @Route("/new", name="new_entry") |
20 | * @return \Symfony\Component\HttpFoundation\Response | 18 | * @return \Symfony\Component\HttpFoundation\Response |
21 | */ | 19 | */ |
@@ -32,7 +30,6 @@ class EntryController extends Controller | |||
32 | $form->handleRequest($request); | 30 | $form->handleRequest($request); |
33 | 31 | ||
34 | if ($form->isValid()) { | 32 | if ($form->isValid()) { |
35 | |||
36 | $content = Extractor::extract($entry->getUrl()); | 33 | $content = Extractor::extract($entry->getUrl()); |
37 | 34 | ||
38 | $entry->setTitle($content->getTitle()); | 35 | $entry->setTitle($content->getTitle()); |
@@ -115,7 +112,7 @@ class EntryController extends Controller | |||
115 | /** | 112 | /** |
116 | * Shows entry content | 113 | * Shows entry content |
117 | * | 114 | * |
118 | * @param Entries $entry | 115 | * @param Entries $entry |
119 | * @Route("/view/{id}", requirements={"id" = "\d+"}, name="view") | 116 | * @Route("/view/{id}", requirements={"id" = "\d+"}, name="view") |
120 | * @return \Symfony\Component\HttpFoundation\Response | 117 | * @return \Symfony\Component\HttpFoundation\Response |
121 | */ | 118 | */ |
@@ -130,8 +127,8 @@ class EntryController extends Controller | |||
130 | /** | 127 | /** |
131 | * Changes read status for an entry | 128 | * Changes read status for an entry |
132 | * | 129 | * |
133 | * @param Request $request | 130 | * @param Request $request |
134 | * @param Entries $entry | 131 | * @param Entries $entry |
135 | * @Route("/archive/{id}", requirements={"id" = "\d+"}, name="archive_entry") | 132 | * @Route("/archive/{id}", requirements={"id" = "\d+"}, name="archive_entry") |
136 | * @return \Symfony\Component\HttpFoundation\RedirectResponse | 133 | * @return \Symfony\Component\HttpFoundation\RedirectResponse |
137 | */ | 134 | */ |
@@ -151,8 +148,8 @@ class EntryController extends Controller | |||
151 | /** | 148 | /** |
152 | * Changes favorite status for an entry | 149 | * Changes favorite status for an entry |
153 | * | 150 | * |
154 | * @param Request $request | 151 | * @param Request $request |
155 | * @param Entries $entry | 152 | * @param Entries $entry |
156 | * @Route("/star/{id}", requirements={"id" = "\d+"}, name="star_entry") | 153 | * @Route("/star/{id}", requirements={"id" = "\d+"}, name="star_entry") |
157 | * @return \Symfony\Component\HttpFoundation\RedirectResponse | 154 | * @return \Symfony\Component\HttpFoundation\RedirectResponse |
158 | */ | 155 | */ |
@@ -172,8 +169,8 @@ class EntryController extends Controller | |||
172 | /** | 169 | /** |
173 | * Deletes entry | 170 | * Deletes entry |
174 | * | 171 | * |
175 | * @param Request $request | 172 | * @param Request $request |
176 | * @param Entries $entry | 173 | * @param Entries $entry |
177 | * @Route("/delete/{id}", requirements={"id" = "\d+"}, name="delete_entry") | 174 | * @Route("/delete/{id}", requirements={"id" = "\d+"}, name="delete_entry") |
178 | * @return \Symfony\Component\HttpFoundation\RedirectResponse | 175 | * @return \Symfony\Component\HttpFoundation\RedirectResponse |
179 | */ | 176 | */ |