Skip to content

Commit

Permalink
feat(jans-auth,jans-cli,jans-config-api): changes to handle new attri…
Browse files Browse the repository at this point in the history
…bute description in Client object and new custom script type
  • Loading branch information
pujavs committed Mar 15, 2022
1 parent a096110 commit d64e042
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

package io.jans.configapi.rest.resource.auth;

import static io.jans.as.model.util.Util.escapeLog;
import io.jans.configapi.core.rest.ProtectedApi;
import io.jans.configapi.util.ApiAccessConstants;
import io.jans.configapi.util.ApiConstants;
Expand Down Expand Up @@ -66,7 +67,9 @@ public Response getCustomScriptsByTypePattern(@PathParam(ApiConstants.TYPE) @Not
@Path(PATH_SEPARATOR + ApiConstants.INUM + PATH_SEPARATOR + ApiConstants.INUM_PATH)
@ProtectedApi(scopes = { ApiAccessConstants.SCRIPTS_READ_ACCESS })
public Response getCustomScriptByInum(@PathParam(ApiConstants.INUM) @NotNull String inum) {
log.debug("Custom Script to be fetched - inum:{} ",inum);
if (log.isDebugEnabled()) {
log.debug("Custom Script to be fetched - inum:{} ", escapeLog(inum));
}
CustomScript script = null;
try {
script = this.customScriptService.getScriptByInum(inum);
Expand Down Expand Up @@ -113,7 +116,9 @@ public Response updateScript(@Valid @NotNull CustomScript customScript) {
@ProtectedApi(scopes = { ApiAccessConstants.SCRIPTS_DELETE_ACCESS })
public Response deleteScript(@PathParam(ApiConstants.INUM) @NotNull String inum) {
try {
log.debug("Custom Script Resource to delete - inum:{}",inum);
if (log.isDebugEnabled()) {
log.debug("Custom Script Resource to delete - inum:{}",escapeLog(inum));
}
CustomScript existingScript = customScriptService.getScriptByInum(inum);
customScriptService.remove(existingScript);
return Response.noContent().build();
Expand Down

0 comments on commit d64e042

Please sign in to comment.