You've already forked nginx-proxy-manager
							
							
				mirror of
				https://github.com/NginxProxyManager/nginx-proxy-manager.git
				synced 2025-10-30 18:05:34 +03:00 
			
		
		
		
	
		
			
				
	
	
		
			16 lines
		
	
	
		
			281 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			16 lines
		
	
	
		
			281 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| import Access from "../access.js";
 | |
| 
 | |
| export default () => {
 | |
| 	return (_, res, next) => {
 | |
| 		res.locals.access = null;
 | |
| 		const access = new Access(res.locals.token || null);
 | |
| 		access
 | |
| 			.load()
 | |
| 			.then(() => {
 | |
| 				res.locals.access = access;
 | |
| 				next();
 | |
| 			})
 | |
| 			.catch(next);
 | |
| 	};
 | |
| };
 |