KEYCLOAK-2255 Location header should return IdP alias instead of provider ID.

This commit is contained in:
Dane Barentine 2016-01-04 11:30:57 -08:00
parent dd6b05224d
commit d8d0298498

View file

@ -170,7 +170,7 @@ public class IdentityProvidersResource {
adminEvent.operation(OperationType.CREATE).resourcePath(uriInfo, identityProvider.getInternalId())
.representation(representation).success();
return Response.created(uriInfo.getAbsolutePathBuilder().path(representation.getProviderId()).build()).build();
return Response.created(uriInfo.getAbsolutePathBuilder().path(representation.getAlias()).build()).build();
} catch (ModelDuplicateException e) {
return ErrorResponse.exists("Identity Provider " + representation.getAlias() + " already exists");
}