File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed 
src/agent/src/Chat/MessageStore Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -56,6 +56,6 @@ public function clear(): void
5656
5757    public  function  withSession (AbstractUid TimeBasedUidInterface $ sessionMessageStoreInterface SessionAwareMessageStoreInterface 
5858    {
59-         return  new  $ this $ this cache , $ sessiontoRfc4122 (), $ this ttl );
59+         return  new  self ($ this cache , $ sessiontoRfc4122 (), $ this ttl );
6060    }
6161}
Original file line number Diff line number Diff line change 1515use  Symfony \AI \Agent \Chat \SessionAwareMessageStoreInterface ;
1616use  Symfony \AI \Platform \Message \MessageBag ;
1717use  Symfony \AI \Platform \Message \MessageBagInterface ;
18+ use  Symfony \AI \Platform \Message \MessageInterface ;
1819use  Symfony \Component \Uid \AbstractUid ;
1920use  Symfony \Component \Uid \TimeBasedUidInterface ;
2021
2122final  class  InMemoryStore implements  MessageStoreInterface, SessionAwareMessageStoreInterface
2223{
2324    /** 
24-      * @var MessageBagInterface [] 
25+      * @var MessageInterface [] 
2526     */ 
2627    private  array  $ messages
2728    private  (AbstractUid TimeBasedUidInterface null  $ sessionnull ;
@@ -43,7 +44,7 @@ public function load(): MessageBagInterface
4344            return  new  MessageBag (...$ this messages );
4445        }
4546
46-         return  $ this messages [$ this session ->toRfc4122 ()] ??  new   MessageBag ( );
47+         return  new   MessageBag ( $ this messages [$ this session ->toRfc4122 ()]);
4748    }
4849
4950    public  function  clear (): void 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments