Skip to content
This repository has been archived by the owner on Jul 17, 2023. It is now read-only.

Commit

Permalink
Samples Refactor - auto-format ApiController
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuatcasey committed Nov 27, 2019
1 parent 0bfa77d commit 9885428
Showing 1 changed file with 9 additions and 27 deletions.
Original file line number Diff line number Diff line change
@@ -1,27 +1,5 @@
/*******************************************************************************
* Cloud Foundry
* Copyright (c) [2009-2016] Pivotal Software, Inc. All Rights Reserved.
*
* This product is licensed to you under the Apache License, Version 2.0 (the "License").
* You may not use this product except in compliance with the License.
*
* This product includes a number of subcomponents with
* separate copyright notices and license terms. Your use of these
* subcomponents is subject to the terms and conditions of the
* subcomponent's license, as noted in the LICENSE file.
*******************************************************************************/

package org.cloudfoundry.identity.api.web;

import java.io.IOException;
import java.io.InputStreamReader;
import java.security.Principal;
import java.util.HashMap;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.context.expression.MapAccessor;
import org.springframework.core.io.Resource;
import org.springframework.expression.Expression;
Expand All @@ -34,10 +12,14 @@
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.View;

/**
* @author Dave Syer
*
*/
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.InputStreamReader;
import java.security.Principal;
import java.util.HashMap;
import java.util.Map;

@Controller
public class ApiController {

Expand Down Expand Up @@ -112,7 +94,7 @@ public String getContentType() {

@Override
public void render(Map<String, ?> model, HttpServletRequest request, HttpServletResponse response)
throws Exception {
throws Exception {
if (response.getContentType() == null) {
response.setContentType(getContentType());
}
Expand Down

0 comments on commit 9885428

Please sign in to comment.