import { HttpInterceptorFn } from '@angular/common/http';

export const CredentialsInterceptor: HttpInterceptorFn = (req, next) => {
  // Clona a requisição e adiciona withCredentials: true
  const clonedRequest = req.clone({
    withCredentials: true
  });
  return next(clonedRequest);
};