Code Duplication    Length = 6-6 lines in 2 locations

src/Surfnet/StepupRa/RaBundle/Controller/Vetting/SmsController.php 1 location

@@ 118-123 (lines=6) @@
115
116
        /** @var SubmitButton $cancelButton */
117
        $cancelButton = $form->get('cancel');
118
        if ($cancelButton->isClicked()) {
119
            $this->getVettingService()->cancelProcedure($procedureId);
120
            $this->addFlash('info', $this->get('translator')->trans('ra.vetting.flash.cancelled'));
121
122
            return $this->redirectToRoute('ra_vetting_search');
123
        }
124
125
        if (!$form->isValid()) {
126
            $logger->notice(

src/Surfnet/StepupRa/RaBundle/Controller/VettingController.php 1 location

@@ 173-178 (lines=6) @@
170
171
        /** @var SubmitButton $cancelButton */
172
        $cancelButton = $form->get('cancel');
173
        if ($cancelButton->isClicked()) {
174
            $this->getVettingService()->cancelProcedure($procedureId);
175
            $this->addFlash('info', $this->get('translator')->trans('ra.vetting.flash.cancelled'));
176
177
            return $this->redirectToRoute('ra_vetting_search');
178
        }
179
180
        $vettingService = $this->getVettingService();
181
        $commonName = $vettingService->getIdentityCommonName($procedureId);