Update cors
This commit is contained in:
@@ -14,7 +14,10 @@ public class WebConfig {
|
||||
@Override
|
||||
public void addCorsMappings(CorsRegistry registry) {
|
||||
registry.addMapping("/**") // apply to all endpoints
|
||||
.allowedOrigins("http://localhost:4200") // Angular dev server
|
||||
.allowedOrigins(
|
||||
"http://localhost:4200", // Angular dev server
|
||||
"https://insurance.hzwnrw.my" // Production frontend over HTTPS
|
||||
) // Angular dev server
|
||||
.allowedMethods("GET", "POST", "PUT", "DELETE", "OPTIONS")
|
||||
.allowedHeaders("*")
|
||||
.allowCredentials(true);
|
||||
|
||||
Reference in New Issue
Block a user