François Drouhard %!s(int64=2) %!d(string=hai) anos
pai
achega
c90cf7835d
Modificáronse 5 ficheiros con 256 adicións e 260 borrados
  1. 28 28
      composer.json
  2. 222 217
      composer.lock
  3. 2 2
      src/Entity/User.php
  4. 4 4
      src/Service/Mattermost.php
  5. 0 9
      symfony.lock

+ 28 - 28
composer.json

@@ -14,42 +14,42 @@
         "phpdocumentor/reflection-docblock": "^5.3",
         "sensio/framework-extra-bundle": "^6.2",
         "symfony/apache-pack": "^1.0",
-        "symfony/asset": "^5.4",
-        "symfony/console": "^5.4",
-        "symfony/dotenv": "^5.4",
-        "symfony/expression-language": "^5.4",
+        "symfony/asset": "6.1.*",
+        "symfony/console": "6.1.*",
+        "symfony/dotenv": "6.1.*",
+        "symfony/expression-language": "6.1.*",
         "symfony/flex": "^2.2",
-        "symfony/form": "^5.4",
-        "symfony/framework-bundle": "^5.4",
-        "symfony/http-client": "5.4.*",
-        "symfony/mailer": "5.4.*",
+        "symfony/form": "6.1.*",
+        "symfony/framework-bundle": "6.1.*",
+        "symfony/http-client": "6.1.*",
+        "symfony/mailer": "6.1.*",
         "symfony/monolog-bundle": "^3.1",
-        "symfony/process": "^5.4",
-        "symfony/property-access": "5.4.*",
-        "symfony/property-info": "5.4.*",
-        "symfony/proxy-manager-bridge": "5.4.*",
-        "symfony/runtime": "5.4.*",
-        "symfony/security-bundle": "^5.4",
-        "symfony/serializer": "5.4.*",
-        "symfony/translation": "^5.4",
-        "symfony/twig-bundle": "^5.4",
-        "symfony/validator": "^5.4",
-        "symfony/web-link": "^5.4",
+        "symfony/process": "6.1.*",
+        "symfony/property-access": "6.1.*",
+        "symfony/property-info": "6.1.*",
+        "symfony/proxy-manager-bridge": "6.1.*",
+        "symfony/runtime": "6.1.*",
+        "symfony/security-bundle": "6.1.*",
+        "symfony/serializer": "6.1.*",
+        "symfony/translation": "6.1.*",
+        "symfony/twig-bundle": "6.1.*",
+        "symfony/validator": "6.1.*",
+        "symfony/web-link": "6.1.*",
         "symfony/webpack-encore-bundle": "^1.12",
-        "symfony/yaml": "^5.4",
+        "symfony/yaml": "6.1.*",
         "twig/extra-bundle": "^3.4",
         "twig/twig": "^2.12|^3.0"
     },
     "require-dev": {
         "phpunit/phpunit": "^9.5",
-        "symfony/browser-kit": "^5.4",
-        "symfony/css-selector": "^5.4",
-        "symfony/debug-bundle": "^5.4",
+        "symfony/browser-kit": "6.1.*",
+        "symfony/css-selector": "6.1.*",
+        "symfony/debug-bundle": "6.1.*",
         "symfony/maker-bundle": "^1.47",
-        "symfony/phpunit-bridge": "^5.4",
-        "symfony/stopwatch": "^5.4",
-        "symfony/var-dumper": "^5.4",
-        "symfony/web-profiler-bundle": "^5.4"
+        "symfony/phpunit-bridge": "6.1.*",
+        "symfony/stopwatch": "6.1.*",
+        "symfony/var-dumper": "6.1.*",
+        "symfony/web-profiler-bundle": "6.1.*"
     },
     "config": {
         "platform":{
@@ -100,7 +100,7 @@
     "extra": {
         "symfony": {
             "allow-contrib": false,
-            "require": "5.4.*"
+            "require": "6.1.*"
         }
     }
 }

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 222 - 217
composer.lock


+ 2 - 2
src/Entity/User.php

@@ -106,7 +106,7 @@ class User implements UserInterface,PasswordAuthenticatedUserInterface
         return (string) $this->username;
     }
 
-    public function getUserIdentifier(): ?string
+    public function getUserIdentifier(): string
     {
         return $this->username;
     }
@@ -227,7 +227,7 @@ class User implements UserInterface,PasswordAuthenticatedUserInterface
     /**
      * @see UserInterface
      */
-    public function getRoles(): ?array
+    public function getRoles(): array
     {
         $roles = $this->roles;
         return array_unique($roles);

+ 4 - 4
src/Service/Mattermost.php

@@ -5,8 +5,8 @@ namespace App\Service;
 
 use App\Entity\Film;
 use App\Entity\User;
-use Symfony\Component\HttpFoundation\Session\Flash\FlashBagInterface;
-use Symfony\Component\Routing\Generator\UrlGeneratorInterface;;
+use Symfony\Component\HttpFoundation\RequestStack;
+use Symfony\Component\Routing\Generator\UrlGeneratorInterface;
 
 /**
  * Envoi notifs mattermost
@@ -22,7 +22,7 @@ class Mattermost
         protected string $channelId,
         protected string $channelIdAdmin,
         protected UrlGeneratorInterface $router,
-        protected FlashBagInterface $flashBagInterface)
+        protected RequestStack $requestStack)
     {
         $this->url = $url . "/api/v4/posts";
     }
@@ -52,7 +52,7 @@ class Mattermost
             // ferme la ressource cURL et libère les ressources systèmes
             curl_close($ch);
         } catch (\Exception $e) {
-            $this->flashBagInterface->add('error', "L'envoi vers mattermost a échoué.");
+            $this->requestStack->getSession()->getFlashBag->add('error', "L'envoi vers mattermost a échoué.");
         }
         
     }

+ 0 - 9
symfony.lock

@@ -431,15 +431,9 @@
     "symfony/polyfill-php72": {
         "version": "v1.11.0"
     },
-    "symfony/polyfill-php73": {
-        "version": "v1.11.0"
-    },
     "symfony/polyfill-php80": {
         "version": "v1.17.1"
     },
-    "symfony/polyfill-php81": {
-        "version": "v1.23.0"
-    },
     "symfony/process": {
         "version": "v4.2.8"
     },
@@ -483,9 +477,6 @@
     "symfony/security-csrf": {
         "version": "v4.2.8"
     },
-    "symfony/security-guard": {
-        "version": "v4.2.8"
-    },
     "symfony/security-http": {
         "version": "v4.2.8"
     },

Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio