Explorar o código

dateTime Range

Vincent GUFFON %!s(int64=4) %!d(string=hai) anos
pai
achega
682fad5c6a
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      src/Entity/Access/Access.php

+ 3 - 0
src/Entity/Access/Access.php

@@ -290,6 +290,9 @@ class Access implements UserInterface
 
     public function setHistorical(array $historical): self
     {
+        if(!$historical['past'] && !$historical['present'] && !$historical['future'])
+            $historical['present'] = true;
+
         $this->setting['historical'] = $historical;
         return $this;
     }