aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Controller/ConfigController.php
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2015-12-22 13:00:37 +0100
committerJeremy Benoist <jeremy.benoist@gmail.com>2016-01-15 09:35:38 +0100
commit5c895a7fd15822856fb407910264c5d95e1e223c (patch)
treea850ff9ccfd8067d4f8cdd341a2dda4324008afa /src/Wallabag/CoreBundle/Controller/ConfigController.php
parent619cc45359ead519b64129181a07e14160fbbfcb (diff)
downloadwallabag-5c895a7fd15822856fb407910264c5d95e1e223c.tar.gz
wallabag-5c895a7fd15822856fb407910264c5d95e1e223c.tar.zst
wallabag-5c895a7fd15822856fb407910264c5d95e1e223c.zip
Update bundle & stock file
- update stock file (AppKernel, app.php, etc ..) from SymfonyStandard edition) - update bundle to latest release - remove security on profiler
Diffstat (limited to 'src/Wallabag/CoreBundle/Controller/ConfigController.php')
-rw-r--r--src/Wallabag/CoreBundle/Controller/ConfigController.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/Wallabag/CoreBundle/Controller/ConfigController.php b/src/Wallabag/CoreBundle/Controller/ConfigController.php
index f51ccaa4..d0cf91de 100644
--- a/src/Wallabag/CoreBundle/Controller/ConfigController.php
+++ b/src/Wallabag/CoreBundle/Controller/ConfigController.php
@@ -8,6 +8,7 @@ use Symfony\Component\HttpFoundation\JsonResponse;
8use Symfony\Component\HttpFoundation\Request; 8use Symfony\Component\HttpFoundation\Request;
9use Wallabag\CoreBundle\Entity\Config; 9use Wallabag\CoreBundle\Entity\Config;
10use Wallabag\CoreBundle\Entity\TaggingRule; 10use Wallabag\CoreBundle\Entity\TaggingRule;
11use Wallabag\CoreBundle\Form\Type\ConfigType;
11use Wallabag\CoreBundle\Form\Type\ChangePasswordType; 12use Wallabag\CoreBundle\Form\Type\ChangePasswordType;
12use Wallabag\CoreBundle\Form\Type\NewUserType; 13use Wallabag\CoreBundle\Form\Type\NewUserType;
13use Wallabag\CoreBundle\Form\Type\RssType; 14use Wallabag\CoreBundle\Form\Type\RssType;
@@ -31,7 +32,7 @@ class ConfigController extends Controller
31 $user = $this->getUser(); 32 $user = $this->getUser();
32 33
33 // handle basic config detail (this form is defined as a service) 34 // handle basic config detail (this form is defined as a service)
34 $configForm = $this->createForm('config', $config, array('action' => $this->generateUrl('config'))); 35 $configForm = $this->createForm(ConfigType::class, $config, array('action' => $this->generateUrl('config')));
35 $configForm->handleRequest($request); 36 $configForm->handleRequest($request);
36 37
37 if ($configForm->isValid()) { 38 if ($configForm->isValid()) {
@@ -51,7 +52,7 @@ class ConfigController extends Controller
51 } 52 }
52 53
53 // handle changing password 54 // handle changing password
54 $pwdForm = $this->createForm(new ChangePasswordType(), null, array('action' => $this->generateUrl('config').'#set4')); 55 $pwdForm = $this->createForm(ChangePasswordType::class, null, array('action' => $this->generateUrl('config').'#set4'));
55 $pwdForm->handleRequest($request); 56 $pwdForm->handleRequest($request);
56 57
57 if ($pwdForm->isValid()) { 58 if ($pwdForm->isValid()) {
@@ -67,7 +68,7 @@ class ConfigController extends Controller
67 } 68 }
68 69
69 // handle changing user information 70 // handle changing user information
70 $userForm = $this->createForm(new UserInformationType(), $user, array( 71 $userForm = $this->createForm(UserInformationType::class, $user, array(
71 'validation_groups' => array('Profile'), 72 'validation_groups' => array('Profile'),
72 'action' => $this->generateUrl('config').'#set3', 73 'action' => $this->generateUrl('config').'#set3',
73 )); 74 ));
@@ -85,7 +86,7 @@ class ConfigController extends Controller
85 } 86 }
86 87
87 // handle rss information 88 // handle rss information
88 $rssForm = $this->createForm(new RssType(), $config, array('action' => $this->generateUrl('config').'#set2')); 89 $rssForm = $this->createForm(RssType::class, $config, array('action' => $this->generateUrl('config').'#set2'));
89 $rssForm->handleRequest($request); 90 $rssForm->handleRequest($request);
90 91
91 if ($rssForm->isValid()) { 92 if ($rssForm->isValid()) {
@@ -102,7 +103,7 @@ class ConfigController extends Controller
102 103
103 // handle tagging rule 104 // handle tagging rule
104 $taggingRule = new TaggingRule(); 105 $taggingRule = new TaggingRule();
105 $newTaggingRule = $this->createForm(new TaggingRuleType(), $taggingRule, array('action' => $this->generateUrl('config').'#set5')); 106 $newTaggingRule = $this->createForm(TaggingRuleType::class, $taggingRule, array('action' => $this->generateUrl('config').'#set5'));
106 $newTaggingRule->handleRequest($request); 107 $newTaggingRule->handleRequest($request);
107 108
108 if ($newTaggingRule->isValid()) { 109 if ($newTaggingRule->isValid()) {
@@ -122,7 +123,7 @@ class ConfigController extends Controller
122 $newUser = $userManager->createUser(); 123 $newUser = $userManager->createUser();
123 // enable created user by default 124 // enable created user by default
124 $newUser->setEnabled(true); 125 $newUser->setEnabled(true);
125 $newUserForm = $this->createForm(new NewUserType(), $newUser, array( 126 $newUserForm = $this->createForm(NewUserType::class, $newUser, array(
126 'validation_groups' => array('Profile'), 127 'validation_groups' => array('Profile'),
127 'action' => $this->generateUrl('config').'#set5', 128 'action' => $this->generateUrl('config').'#set5',
128 )); 129 ));