working example of interceptor