mirror of
				https://github.com/invoiceninja/invoiceninja.git
				synced 2025-11-04 04:17:34 -05:00 
			
		
		
		
	Fixes for locale middleware
This commit is contained in:
		
							parent
							
								
									88c6fc6d4c
								
							
						
					
					
						commit
						bee623af75
					
				@ -35,7 +35,13 @@ class Locale
 | 
			
		||||
        } elseif (auth('contact')->user()) {
 | 
			
		||||
            App::setLocale(auth('contact')->user()->client->locale());
 | 
			
		||||
        } elseif (auth()->user()) {
 | 
			
		||||
 | 
			
		||||
            try{
 | 
			
		||||
                App::setLocale(auth()->user()->company()->getLocale());
 | 
			
		||||
            }
 | 
			
		||||
            catch(\Exception $e){
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
        } else {
 | 
			
		||||
            App::setLocale(config('ninja.i18n.locale'));
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user