title: Angular 4 interceptor not setting headers
body: <p>For some reason the headers on my http request are not beeing sent.</p>
  
  <p>I am using one interceptor with the following code.</p>
  
  <pre><code>    @Injectable()
  export class AuthInterceptor implements HttpInterceptor {
    constructor() {}
    intercept(req: HttpRequest&lt;any&gt;, next: HttpHandler): Observable&lt;HttpEvent&lt;any&gt;&gt; {
  
        const token: string = localStorage.getItem('token');
  
        if (token) {
            req = req.clone({ headers: req.headers.set('Authorization', 'Bearer ' + token) });
  
      return next.handle(req);
    }
  }
  </code></pre>
  
  <p>After seeing the received headers on the api there is no authorization header.</p>
  
  <p>I don´t know if i am doing something wrong on the API side. I have the following cors configuration.</p>
  
  <pre><code>module.exports = (req, res, next) =&gt; {
  res.setHeader('Access-Control-Allow-Origin', '*');
  res.setHeader('Access-Control-Allow-Methods', 'GET, POST, OPTIONS, PUT, PATCH, DELETE');
  res.setHeader('Access-Control-Allow-Headers', 'X-Requested-With,content-type,Authorization');
  res.setHeader('Access-Control-Allow-Credentials', true);
  next();
  };
  </code></pre>
  
  <p>I thank you in advance.</p>