title: My API returns me 1 instead of JSON object
body: <p>I am using Spring Boot to build a simple API that retrieves an object named MutualFund.
  I have a get request that returns a MutualFund object. As I tested this method using postman, I receive a 200 status and a value of 1 in the response body. Literally a 1. Not in quotes. The value 1</p>
  <p>I want the MutualFund object to be shown in the response body like:</p>
  <pre><code>{
  &quot;name&quot;: &quot;someFund&quot;,
  &quot;price&quot;: 2.00
  }
  </code></pre>
  <p>This is my controller:</p>
  <pre><code>@RestController
  public class MutualFundController {
  
      @Autowired
      MutualFundRepo repo;
  
      @GetMapping(&quot;/mutualFundNav/{name}&quot;)
      MutualFund getMutualFundByName(@PathVariable String name) {
          return repo.findByName(name);
      }
  
  }
  </code></pre>
  <p>Quick tip, the URL I use for the GET request is</p>
  <pre><code>localhost:8080/mutualFundNav/BenjaminFranklin
  </code></pre>
  <p>In my case, &quot;BenjaminFranklin&quot; is the name of the mutual fund</p>