diff --git a/src/main/java/org/pesmypetcare/webservice/WebserviceApplication.java b/src/main/java/org/pesmypetcare/webservice/WebserviceApplication.java index 64101ce5..10513b7b 100644 --- a/src/main/java/org/pesmypetcare/webservice/WebserviceApplication.java +++ b/src/main/java/org/pesmypetcare/webservice/WebserviceApplication.java @@ -26,8 +26,7 @@ public WebMvcConfigurer corsConfigurer() { return new WebMvcConfigurer() { @Override public void addCorsMappings(CorsRegistry registry) { - registry.addMapping("/**").allowedOrigins("http://localhost:4200", "https://localhost:4200", - "https://my-pet-care-web.herokuapp.com", "http://my-pet-care-web.herokuapp.com"); + registry.addMapping("/**").allowedOrigins("*"); } }; } diff --git a/src/main/java/org/pesmypetcare/webservice/controller/petmanager/PetRestController.java b/src/main/java/org/pesmypetcare/webservice/controller/petmanager/PetRestController.java index a28df382..21277e27 100644 --- a/src/main/java/org/pesmypetcare/webservice/controller/petmanager/PetRestController.java +++ b/src/main/java/org/pesmypetcare/webservice/controller/petmanager/PetRestController.java @@ -25,7 +25,7 @@ */ @RestController @RequestMapping("/pet") -@CrossOrigin(origins = "http://localhost:4200") +@CrossOrigin(origins = "*") public class PetRestController { @Autowired private PetService petService;