Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
amontenegro committed Apr 14, 2023
1 parent 58b99c5 commit 740611c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@
import org.orcid.core.manager.impl.OrcidUrlManager;
import org.orcid.core.oauth.OAuthError;
import org.orcid.core.oauth.OAuthErrorUtils;
import org.orcid.core.utils.DateUtils;
import org.orcid.core.utils.OrcidStringUtils;
import org.orcid.core.version.ApiSection;
import org.orcid.jaxb.model.message.DeprecatedDate;
import org.orcid.jaxb.model.message.ErrorDesc;
Expand All @@ -51,8 +53,6 @@
import org.orcid.jaxb.model.message.OrcidMessage;
import org.orcid.jaxb.model.message.PrimaryRecord;
import org.orcid.pojo.ajaxForm.PojoUtil;
import org.orcid.core.utils.DateUtils;
import org.orcid.core.utils.OrcidStringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.MessageSource;
Expand Down Expand Up @@ -102,7 +102,6 @@ public class OrcidExceptionMapper implements ExceptionMapper<Throwable> {
@Override
public Response toResponse(Throwable t) {
// Whatever exception has been caught, make sure we log it.
t.printStackTrace();
String clientId = securityManager.getClientIdFromAPIRequest();
if (t instanceof NotFoundException) {
logShortError(t, clientId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,8 @@
import org.glassfish.jersey.message.XmlHeader;
import org.orcid.api.identifiers.delegator.IdentifierApiServiceDelegator;
import org.orcid.core.api.OrcidApiConstants;
import org.orcid.jaxb.model.message.ScopeConstants;
import org.springframework.stereotype.Component;


//import io.swagger.v3.oas.annotations.Operation;
//TODOSWAGGER
//import com.sun.jersey.api.provider.jaxb.XmlHeader;
/*
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import io.swagger.annotations.ApiResponse;
import io.swagger.annotations.ApiResponses;
import io.swagger.annotations.Authorization;
import io.swagger.annotations.AuthorizationScope;
*/

//@Api("Identifier API")
@Component
@Path("/v{version: 2.0|2.1|3.0}" + OrcidApiConstants.IDENTIFIER_PATH)
public class IdentifierApiServiceImpl {
Expand All @@ -46,10 +31,6 @@ public void setServiceDelegator(IdentifierApiServiceDelegator serviceDelegator)
@Produces(value = { MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML })
@Path("")
@XmlHeader(xmllocation)
/*@Operation(description = "Fetch identifier type map. Defaults to English descriptions", authorizations = { @Authorization(value = "orcid_two_legs", scopes = { @AuthorizationScope(scope = ScopeConstants.READ_PUBLIC, description = "you need this") }) })
@ApiResponses(value = { @ApiResponse(code = 200, message = "")})
*/
//public Response viewIdentifierTypes(@ApiParam() @QueryParam("locale") String locale) {
public Response viewIdentifierTypes(@QueryParam("locale") String locale) {
if (locale == null || locale.isEmpty())
locale = "en";
Expand Down

0 comments on commit 740611c

Please sign in to comment.