mirror of
				https://github.com/mealie-recipes/mealie.git
				synced 2025-10-30 17:53:31 -04:00 
			
		
		
		
	Co-authored-by: Michael Genson <71845777+michael-genson@users.noreply.github.com> Co-authored-by: Kuchenpirat <24235032+Kuchenpirat@users.noreply.github.com>
		
			
				
	
	
		
			9 lines
		
	
	
		
			300 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
			
		
		
	
	
			9 lines
		
	
	
		
			300 B
		
	
	
	
		
			TypeScript
		
	
	
	
	
	
| export default defineNuxtRouteMiddleware(() => {
 | |
|   const { user } = useMealieAuth();
 | |
|   // If the user is not allowed to access advanced features redirect to the home page
 | |
|   if (!user.value?.advanced) {
 | |
|     console.warn("User is not allowed to access advanced features");
 | |
|     navigateTo("/");
 | |
|   }
 | |
| });
 |