title: Symfony 3.4 - Make sure annotations are installed and enabled
body: <p>I am trying to implement a forgot password feature to an existing Symfony app. So fare I have the password request done. The user puts in it's email and an email is sent with a token. The return URL looks like this:</p>
  <p>/intranet/password-change/f74eab6dca8b5ed6fd46e7893221254b655f94799589e0b83c</p>
  <p>Normally a forme should show but when i visite that URL i get this message:</p>
  <blockquote>
  <p>Class App\Controller\ResettingController does not exist in
  /public_html/intranet/src/AppBundle/Controller/ (which is
  being imported from &quot;/public_html/intranet/app/config/routing.yml&quot;).
  Make sure annotations are installed and enabled.</p>
  </blockquote>
  <p>I don't get it ... I have the controller set up at the right place and the route should be taken care of by the annotations.</p>
  <p>My routing file:</p>
  <pre><code>app:
      resource: &quot;@AppBundle/Controller/&quot;
      type:     annotation
  
  coop_tilleuls_forgot_password.reset:
      path:   '/api/forgot-password'
      defaults:  { _controller:  coop_tilleuls_forgot_password.controller.forgot_password:resetPasswordAction}
      methods:  [POST]
  
  coop_tilleuls_forgot_password.update:
      path:   '/api/reset-password/{tokenValue}'
      defaults:  { _controller: coop_tilleuls_forgot_password.controller.forgot_password:updatePasswordAction} 
  </code></pre>
  <p>as for my resseting class it's in
  /public_html/intranet/src/AppBundle/Controller</p>
  <p>And looks like this:</p>
  <pre><code>&lt;?php 
  // src/Controller/ResettingController.php
  namespace App\Controller;
  use Symfony\Component\Routing\Annotation\Route;
  use Symfony\Bundle\FrameworkBundle\Controller\Controller;
  use Symfony\Component\HttpFoundation\Response;
  use Symfony\Component\HttpFoundation\Request;
  use Symfony\Component\Validator\Constraints\Email;
  use Symfony\Component\Validator\Constraints\NotBlank;
  use Symfony\Component\Form\Extension\Core\Type\EmailType;
  use Symfony\Component\Security\Csrf\TokenGenerator\TokenGeneratorInterface;
  use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
  use Symfony\Component\Validator\Validator\ValidatorInterface;
  use Symfony\Component\Translation\TranslatorInterface;
  use Symfony\Component\Security\Core\Encoder\UserPasswordEncoderInterface;
  use Symfony\Component\Form\FormErrorIterator;
  use App\Entity\User;
  use App\Services\Mailer;
  use App\Form\ResettingType;
  /**
   * @Route(&quot;/password-change&quot;)
   */
  class ResettingController extends Controller
  {
      /**
       * @Route(&quot;/{id}/{token}&quot;, name=&quot;resetting&quot;)
       */
      public function resetting(User $user, $token, Request $request, UserPasswordEncoderInterface $passwordEncoder)
      {
          // interdit l'accès à la page si:
          // le token associé au membre est null
          // le token enregistré en base et le token présent dans l'url ne sont pas égaux
          // le token date de plus de 10 minutes
          if ($user-&gt;getToken() === null || $token !== $user-&gt;getToken() || !$this-&gt;isRequestInTime($user-&gt;getPasswordRequestedAt()))
          {
              throw new AccessDeniedHttpException();
          }
          $form = $this-&gt;createForm(ResettingType::class, $user);
          $form-&gt;handleRequest($request);
          if($form-&gt;isSubmitted() &amp;&amp; $form-&gt;isValid())
          {
              $password = $passwordEncoder-&gt;encodePassword($user, $user-&gt;getPlainPassword());
              $user-&gt;setPassword($password);
              // réinitialisation du token à null pour qu'il ne soit plus réutilisable
              $user-&gt;setToken(null);
              $user-&gt;setPasswordRequestedAt(null);
              $em = $this-&gt;getDoctrine()-&gt;getManager();
              $em-&gt;persist($user);
              $em-&gt;flush();
              $request-&gt;getSession()-&gt;getFlashBag()-&gt;add('success', &quot;Votre mot de passe a été modifié.&quot;);
              return $this-&gt;redirectToRoute('security_login_form');
          } 
          return $this-&gt;render('security/resetting.html.twig', [
              'form' =&gt; $form-&gt;createView()
          ]);
          
      }
  }
  </code></pre>
  <p>I am new to symfony so I might be missing something obvious ... I just don't see it lol thx in advance</p>