how can i create a custom global middleware almost same with the user authenticated middleware - Wasp