Putting the right configuration for cors #99

Merged
tonitch merged 1 commits from tonitch/back/CORSresolution into master 2024-03-14 22:35:58 +01:00
5 changed files with 5 additions and 5 deletions

View File

@ -18,7 +18,7 @@ import java.util.Calendar;
import java.util.Date;
@RestController
@CrossOrigin(origins = "http://localhost:5173")
@CrossOrigin(originPatterns = "*", allowCredentials = "true")
public class MockController {
private final BCryptPasswordEncoder passwordEncoder = new BCryptPasswordEncoder();

View File

@ -7,7 +7,7 @@ import org.springframework.web.bind.annotation.RestController;
import ovh.herisson.Clyde.Responses.PingResponse;
@RestController
@CrossOrigin(origins = "http://localhost:5173")
@CrossOrigin(originPatterns = "*", allowCredentials = "true")
public class PingController {
@GetMapping("/ping")

View File

@ -10,7 +10,7 @@ import org.springframework.core.io.Resource;
import ovh.herisson.Clyde.Tables.FileType;
@RestController
@CrossOrigin(origins = "http://localhost:5173")
@CrossOrigin(originPatterns = "*", allowCredentials = "true")
public class StorageController {
private final StorageService storageServ;

View File

@ -9,7 +9,7 @@ import ovh.herisson.Clyde.Services.TokenService;
import ovh.herisson.Clyde.Tables.Token;
@RestController
@CrossOrigin(origins = "http://localhost:5173")
@CrossOrigin(originPatterns = "*", allowCredentials = "true")
public class TokenController {
private final TokenService tokenServ;

View File

@ -12,7 +12,7 @@ import ovh.herisson.Clyde.Tables.User;
@RestController
@CrossOrigin(origins = "http://localhost:5173")
@CrossOrigin(originPatterns = "*", allowCredentials = "true")
public class UserController {
private final UserService userService;