@@ -62,7 +62,7 @@ |
||
| 62 | 62 | ; |
| 63 | 63 | } |
| 64 | 64 | |
| 65 | - foreach ($courses as $course){ |
|
| 65 | + foreach ($courses as $course) { |
|
| 66 | 66 | $event = $cal->newEvent(); |
| 67 | 67 | $name = $course->getCourse()->getName(); |
| 68 | 68 | if ($course->getGroup() !== 0) |
@@ -6,8 +6,6 @@ |
||
| 6 | 6 | use JMS\Serializer\Annotation as JMS; |
| 7 | 7 | use Symfony\Component\Validator\Constraints as Assert; |
| 8 | 8 | |
| 9 | -use Symfony\Component\HttpFoundation\File\UploadedFile; |
|
| 10 | - |
|
| 11 | 9 | /** |
| 12 | 10 | * @ORM\Entity |
| 13 | 11 | * @ORM\HasLifecycleCallbacks |
@@ -9,7 +9,6 @@ |
||
| 9 | 9 | use KI\PonthubBundle\Entity\Other; |
| 10 | 10 | use KI\PonthubBundle\Entity\Serie; |
| 11 | 11 | use KI\PonthubBundle\Entity\Software; |
| 12 | -use KI\PonthubBundle\Entity\Genre; |
|
| 13 | 12 | |
| 14 | 13 | /** |
| 15 | 14 | * Class FileHelper |
@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | ->setReplyTo(array($from->getEmail() => $from->getFirstName().' '.$from->getLastName())) |
| 29 | 29 | ; |
| 30 | 30 | |
| 31 | - foreach($attachments as $attachment){ |
|
| 31 | + foreach ($attachments as $attachment) { |
|
| 32 | 32 | $message->attach(Swift_Attachment::fromPath($attachment["path"])->setFilename($attachment["name"])); |
| 33 | 33 | } |
| 34 | 34 | |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | ->setReplyTo(array('[email protected]' => 'Ras\'Ponts\'ine BDE des Ponts')) |
| 51 | 51 | ; |
| 52 | 52 | |
| 53 | - foreach($attachments as $attachment){ |
|
| 53 | + foreach ($attachments as $attachment) { |
|
| 54 | 54 | $message->attach(Swift_Attachment::fromPath($attachment["path"])->setFilename($attachment["name"])); |
| 55 | 55 | } |
| 56 | 56 | |
@@ -25,9 +25,9 @@ |
||
| 25 | 25 | } |
| 26 | 26 | |
| 27 | 27 | return array( |
| 28 | - 'version' => $out[1][count($out[0])-1], |
|
| 29 | - 'major' => $out[2][count($out[0])-1], |
|
| 30 | - 'minor' => $out[3][count($out[0])-1], |
|
| 28 | + 'version' => $out[1][count($out[0]) - 1], |
|
| 29 | + 'major' => $out[2][count($out[0]) - 1], |
|
| 30 | + 'minor' => $out[3][count($out[0]) - 1], |
|
| 31 | 31 | 'build' => shell_exec('git log --pretty=format:"%h" -n 1'), |
| 32 | 32 | 'date' => (int)shell_exec('git log -1 --pretty=format:%ct') |
| 33 | 33 | ); |
@@ -143,10 +143,10 @@ discard block |
||
| 143 | 143 | array_multisort($ids, SORT_ASC, $locked); |
| 144 | 144 | |
| 145 | 145 | // On renvoie pas mal de données utiles |
| 146 | - $response = Achievement::getLevel($factor * $points); |
|
| 146 | + $response = Achievement::getLevel($factor*$points); |
|
| 147 | 147 | $return = array( |
| 148 | 148 | 'number' => $response['number'], |
| 149 | - 'points' => ceil($factor * $points), |
|
| 149 | + 'points' => ceil($factor*$points), |
|
| 150 | 150 | 'current_level' => $response['current'], |
| 151 | 151 | 'next_level' => isset($response['next']) ? $response['next'] : null, |
| 152 | 152 | 'unlocked' => $unlocked, |
@@ -299,7 +299,7 @@ discard block |
||
| 299 | 299 | if (!$notification->getRead()->contains($user) && !$notification->getRecipient()->contains($user)) |
| 300 | 300 | $return[] = $notification; |
| 301 | 301 | } else |
| 302 | - throw new \Exception('Notification : mode d\'envoi inconnu (' . $mode . ')'); |
|
| 302 | + throw new \Exception('Notification : mode d\'envoi inconnu ('.$mode.')'); |
|
| 303 | 303 | } |
| 304 | 304 | |
| 305 | 305 | // On marque chaque notification récupérée comme lue |
@@ -107,7 +107,7 @@ |
||
| 107 | 107 | if (!(isset($match[1]) && isset($match[2]))) { |
| 108 | 108 | return array(); |
| 109 | 109 | } |
| 110 | - $size = $match[2] * 1000; |
|
| 110 | + $size = $match[2]*1000; |
|
| 111 | 111 | $line = str_replace($match[1], '', $line); |
| 112 | 112 | |
| 113 | 113 | // On exclut tous les fichiers de type non valide |
@@ -47,23 +47,23 @@ |
||
| 47 | 47 | $wrongAnswers = $facegame->getWrongAnswers(); |
| 48 | 48 | $duration = $facegame->getDuration(); |
| 49 | 49 | |
| 50 | - if ($wrongAnswers == 0 && $promoGame == $promoUser - 1 && $duration < 60 * 1000) { |
|
| 50 | + if ($wrongAnswers == 0 && $promoGame == $promoUser - 1 && $duration < 60*1000) { |
|
| 51 | 51 | |
| 52 | 52 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_BEFORE, $user); |
| 53 | 53 | $dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 54 | 54 | |
| 55 | - } else if ($wrongAnswers == 0 && $promoGame == $promoUser && $duration < 60 * 1000) { |
|
| 55 | + } else if ($wrongAnswers == 0 && $promoGame == $promoUser && $duration < 60*1000) { |
|
| 56 | 56 | |
| 57 | 57 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_SELF, $user); |
| 58 | 58 | $dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 59 | 59 | |
| 60 | - } else if ($wrongAnswers == 0 && $promoGame == $promoUser + 1 && $duration < 60 * 1000) { |
|
| 60 | + } else if ($wrongAnswers == 0 && $promoGame == $promoUser + 1 && $duration < 60*1000) { |
|
| 61 | 61 | |
| 62 | 62 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_NEXT, $user); |
| 63 | 63 | $dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 64 | 64 | |
| 65 | 65 | } |
| 66 | - if ($wrongAnswers == 0 && $promoGame < $promoUser && $facegame->getHardcore() && $duration < 60 * 1000) { |
|
| 66 | + if ($wrongAnswers == 0 && $promoGame < $promoUser && $facegame->getHardcore() && $duration < 60*1000) { |
|
| 67 | 67 | |
| 68 | 68 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_OLD, $user); |
| 69 | 69 | $dispatcher->dispatch('upont.achievement', $achievementCheck); |
@@ -142,23 +142,23 @@ |
||
| 142 | 142 | $promoUser = (int)$this->tokenStorage->getToken()->getUser()->getPromo(); |
| 143 | 143 | $promoGame = (int)$game->getPromo(); |
| 144 | 144 | |
| 145 | - if ($wrongAnswers == 0 && $promoGame == $promoUser - 1 && $duration < 60 * 1000) { |
|
| 145 | + if ($wrongAnswers == 0 && $promoGame == $promoUser - 1 && $duration < 60*1000) { |
|
| 146 | 146 | |
| 147 | 147 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_BEFORE); |
| 148 | 148 | $this->dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 149 | 149 | |
| 150 | - } else if ($wrongAnswers == 0 && $promoGame == $promoUser && $duration < 60 * 1000) { |
|
| 150 | + } else if ($wrongAnswers == 0 && $promoGame == $promoUser && $duration < 60*1000) { |
|
| 151 | 151 | |
| 152 | 152 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_SELF); |
| 153 | 153 | $this->dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 154 | 154 | |
| 155 | - } else if ($wrongAnswers == 0 && $promoGame == $promoUser + 1 && $duration < 60 * 1000) { |
|
| 155 | + } else if ($wrongAnswers == 0 && $promoGame == $promoUser + 1 && $duration < 60*1000) { |
|
| 156 | 156 | |
| 157 | 157 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_NEXT); |
| 158 | 158 | $this->dispatcher->dispatch('upont.achievement', $achievementCheck); |
| 159 | 159 | |
| 160 | 160 | } |
| 161 | - if ($wrongAnswers == 0 && $promoGame < $promoUser && $game->getHardcore() && $duration < 60 * 1000) { |
|
| 161 | + if ($wrongAnswers == 0 && $promoGame < $promoUser && $game->getHardcore() && $duration < 60*1000) { |
|
| 162 | 162 | |
| 163 | 163 | $achievementCheck = new AchievementCheckEvent(Achievement::GAME_OLD); |
| 164 | 164 | $this->dispatcher->dispatch('upont.achievement', $achievementCheck); |