CORS SPI - code review
Signed-off-by: Dmitry Telegin <demetrio@carretti.pro>
This commit is contained in:
parent
b0403e2268
commit
da69beed4d
3 changed files with 5 additions and 7 deletions
|
@ -28,8 +28,6 @@ import org.keycloak.provider.Spi;
|
|||
*/
|
||||
public class CorsSpi implements Spi {
|
||||
|
||||
private static final String SPI_ID = "cors";
|
||||
|
||||
@Override
|
||||
public boolean isInternal() {
|
||||
return true;
|
||||
|
@ -37,7 +35,7 @@ public class CorsSpi implements Spi {
|
|||
|
||||
@Override
|
||||
public String getName() {
|
||||
return SPI_ID;
|
||||
return "cors";
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -38,9 +38,9 @@ import org.keycloak.representations.AccessToken;
|
|||
/**
|
||||
* @author <a href="mailto:sthorger@redhat.com">Stian Thorgersen</a>
|
||||
*/
|
||||
public class DefaultCorsImpl implements Cors {
|
||||
public class DefaultCors implements Cors {
|
||||
|
||||
private static final Logger logger = Logger.getLogger(DefaultCorsImpl.class);
|
||||
private static final Logger logger = Logger.getLogger(DefaultCors.class);
|
||||
|
||||
private HttpRequest request;
|
||||
private ResponseBuilder builder;
|
||||
|
@ -51,7 +51,7 @@ public class DefaultCorsImpl implements Cors {
|
|||
private boolean preflight;
|
||||
private boolean auth;
|
||||
|
||||
DefaultCorsImpl(HttpRequest request) {
|
||||
DefaultCors(HttpRequest request) {
|
||||
this.request = request;
|
||||
}
|
||||
|
|
@ -30,7 +30,7 @@ public class DefaultCorsFactory implements CorsFactory {
|
|||
|
||||
@Override
|
||||
public Cors create(KeycloakSession session) {
|
||||
return new DefaultCorsImpl(session.getContext().getHttpRequest());
|
||||
return new DefaultCors(session.getContext().getHttpRequest());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in a new issue