File tree Expand file tree Collapse file tree 1 file changed +1
-5
lines changed 
src/lua/api-gateway/validation/oauth2 Expand file tree Collapse file tree 1 file changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -143,11 +143,7 @@ function _M:extractContextVars(tokenInfo)
143143    cachingObj .oauth_token_scope  =  tokenInfo .token .scope 
144144    cachingObj .oauth_token_client_id  =  tokenInfo .token .client_id 
145145    cachingObj .oauth_token_user_id  =  tokenInfo .token .user_id 
146-     local  oauth_token_expires_at  =  tokenInfo .expires_at 
147-     if  ngx .var .max_auth_local_cache_ttl  ~=  nil  and  ngx .var .max_auth_local_cache_ttl  ~=  ' '  then 
148-         oauth_token_expires_at  =  math.min (oauth_token_expires_at , ngx .var .max_auth_local_cache_ttl  *  1000 )
149-     end 
150-     cachingObj .oauth_token_expires_at  =  oauth_token_expires_at 
146+     cachingObj .oauth_token_expires_at  =  tokenInfo .expires_at  --  NOTE: Assumption: value in ms
151147    return  cachingObj 
152148end 
153149
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments