Added redirect option for production environments