@@ -100,7 +100,7 @@ |
||
100 | 100 | return new RedirectResponse($request->request->get('_target_path')); |
101 | 101 | } |
102 | 102 | // For example : return new RedirectResponse($this->urlGenerator->generate('some_route')); |
103 | - throw new Exception('TODO: provide a valid redirect inside '.__FILE__); |
|
103 | + throw new Exception('TODO: provide a valid redirect inside ' . __FILE__); |
|
104 | 104 | } |
105 | 105 | |
106 | 106 | protected function getLoginUrl() |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | |
35 | 35 | $this->createAssetsDirectoriesConfiguration($container, $config); |
36 | 36 | |
37 | - $locator = new FileLocator(dirname(__DIR__).'/Resources/config'); |
|
37 | + $locator = new FileLocator(dirname(__DIR__) . '/Resources/config'); |
|
38 | 38 | $loader = new YamlFileLoader($container, $locator); |
39 | 39 | $loader->load('services.yaml'); |
40 | 40 | |
@@ -52,14 +52,12 @@ discard block |
||
52 | 52 | { |
53 | 53 | // Upload |
54 | 54 | $uploadDirectory = (!isset($config['obblm.upload_directory'])) ? |
55 | - $uploadDirectory = $container->getParameter('kernel.project_dir') . '/public/obblm/uploads' : |
|
56 | - $config['obblm.upload_directory']; |
|
55 | + $uploadDirectory = $container->getParameter('kernel.project_dir') . '/public/obblm/uploads' : $config['obblm.upload_directory']; |
|
57 | 56 | $container->setParameter('obblm.config.directory.upload', $uploadDirectory); |
58 | 57 | |
59 | 58 | // Image resize cache |
60 | 59 | $uploadDirectory = (!isset($config['obblm.public_cache_directory'])) ? |
61 | - $uploadDirectory = $container->getParameter('kernel.project_dir') . '/public/obblm/cache' : |
|
62 | - $config['obblm.public_cache_directory']; |
|
60 | + $uploadDirectory = $container->getParameter('kernel.project_dir') . '/public/obblm/cache' : $config['obblm.public_cache_directory']; |
|
63 | 61 | $container->setParameter('obblm.config.directory.public.cache', $uploadDirectory); |
64 | 62 | } |
65 | 63 |
@@ -6,7 +6,7 @@ |
||
6 | 6 | { |
7 | 7 | public function getFileToLoad():string |
8 | 8 | { |
9 | - return dirname(__DIR__).'/Resources/config/routing/core.yaml'; |
|
9 | + return dirname(__DIR__) . '/Resources/config/routing/core.yaml'; |
|
10 | 10 | } |
11 | 11 | public function getFormat():string |
12 | 12 | { |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | { |
15 | 15 | } |
16 | 16 | |
17 | - public function getRule():?RuleHelperInterface |
|
17 | + public function getRule(): ?RuleHelperInterface |
|
18 | 18 | { |
19 | 19 | return $this->rule; |
20 | 20 | } |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | $this->rule = $rule; |
25 | 25 | } |
26 | 26 | |
27 | - public function getTeam():?Team |
|
27 | + public function getTeam(): ?Team |
|
28 | 28 | { |
29 | 29 | return $this->team; |
30 | 30 | } |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | return null; |
30 | 30 | } |
31 | 31 | |
32 | - public function uploadLogoIfExists(Team $object, $logoFile):?File |
|
32 | + public function uploadLogoIfExists(Team $object, $logoFile): ?File |
|
33 | 33 | { |
34 | 34 | if ($logoFile) { |
35 | 35 | $this->setObjectSubDirectory($object->getId()); |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | } |
45 | 45 | return null; |
46 | 46 | } |
47 | - public function uploadCoverIfExists(Team $object, $coverFile):?File |
|
47 | + public function uploadCoverIfExists(Team $object, $coverFile): ?File |
|
48 | 48 | { |
49 | 49 | if ($coverFile) { |
50 | 50 | $this->setObjectSubDirectory($object->getId()); |
@@ -10,16 +10,16 @@ |
||
10 | 10 | ****************/ |
11 | 11 | interface RulePlayerInterface |
12 | 12 | { |
13 | - public function setPlayerDefaultValues(PlayerVersion $version):?PlayerVersion; |
|
13 | + public function setPlayerDefaultValues(PlayerVersion $version): ?PlayerVersion; |
|
14 | 14 | public function playerIsDisposable(PlayerVersion $playerVersion):bool; |
15 | - public function getInjury(string $key):?object; |
|
15 | + public function getInjury(string $key): ?object; |
|
16 | 16 | public function getAvailablePlayerKeyTypes(string $roster):array; |
17 | 17 | public function getAvailablePlayerTypes(string $roster):array; |
18 | 18 | |
19 | 19 | /************************** |
20 | 20 | * PLAYER EVOLUTION METHOD |
21 | 21 | *************************/ |
22 | - public function getSppLevel(PlayerVersion $version):?string; |
|
23 | - public function getContextForRoll(array $roll):?array; |
|
24 | - public function getAvailableSkills(?PlayerVersion $version, array $context = null):?ArrayCollection; |
|
22 | + public function getSppLevel(PlayerVersion $version): ?string; |
|
23 | + public function getContextForRoll(array $roll): ?array; |
|
24 | + public function getAvailableSkills(?PlayerVersion $version, array $context = null): ?ArrayCollection; |
|
25 | 25 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | public function getAvailableRosters():ArrayCollection; |
15 | 15 | public function getInjuriesTable():array; |
16 | 16 | public function calculateTeamValue(TeamVersion $version, bool $excludeDisposable = false):int; |
17 | - public function calculateTeamRate(TeamVersion $version):?int; |
|
17 | + public function calculateTeamRate(TeamVersion $version): ?int; |
|
18 | 18 | public function getMaxTeamCost():int; |
19 | 19 | public function getRerollCost(Team $team):int; |
20 | 20 | public function getApothecaryCost(Team $team):int; |
@@ -19,7 +19,7 @@ |
||
19 | 19 | /********** |
20 | 20 | * CACHING |
21 | 21 | *********/ |
22 | - public function getAttachedRule():?Rule; |
|
22 | + public function getAttachedRule(): ?Rule; |
|
23 | 23 | public function setAttachedRule(Rule $rule):self; |
24 | 24 | |
25 | 25 | /*************** |
@@ -87,7 +87,7 @@ |
||
87 | 87 | $pdf->setOption('disable-javascript', true); |
88 | 88 | $pdf->setOption('title', $team->getName()); |
89 | 89 | |
90 | - $fileName = urlencode($team->getName()) . '.pdf'; |
|
90 | + $fileName = urlencode($team->getName()) . '.pdf'; |
|
91 | 91 | |
92 | 92 | return new PdfResponse($pdf->getOutputFromHtml($html), $fileName, null, ResponseHeaderBag::DISPOSITION_INLINE); |
93 | 93 | } |