title: Getting a CORS error in a POST request even without a preflight request being issued
body: <p>I actually do know how to solve this with the Access-Control-Allow-Origin header. But I'm curious as to why is this happening, because there is no OPTIONS preflight being sent on Chrome's Network tab (also checked in Firefox). I can even see the full response on the network tab... So here is the request/response information:</p>
  
  <p><strong>General</strong>:</p>
  
  <p>Request URL:<a href="http://localhost:8080/test/api/login" rel="nofollow noreferrer">http://localhost:8080/test/api/login</a></p>
  
  <p>Request Method:POST</p>
  
  <p>Status Code:200 OK</p>
  
  <p>Remote Address:[::1]:8080</p>
  
  <p>Referrer Policy:no-referrer-when-downgrade</p>
  
  <p><strong>Request Headers</strong>:</p>
  
  <p>Accept:application/json, text/plain, <em>/</em></p>
  
  <p>Accept-Encoding:gzip, deflate, br</p>
  
  <p>Accept-Language:en-US,en;q=0.9</p>
  
  <p>Cache-Control:no-cache</p>
  
  <p>Connection:keep-alive</p>
  
  <p>Content-Length:37</p>
  
  <p>content-type:text/plain</p>
  
  <p>Host:localhost:8080</p>
  
  <p>Origin:<a href="http://localhost:8100" rel="nofollow noreferrer">http://localhost:8100</a></p>
  
  <p>Pragma:no-cache</p>
  
  <p>Referer:<a href="http://localhost:8100/" rel="nofollow noreferrer">http://localhost:8100/</a></p>
  
  <p>User-Agent:Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36</p>
  
  <p><strong>Response Headers</strong>:</p>
  
  <p>Content-Length:12</p>
  
  <p>Content-Type:application/json;charset=UTF-8</p>
  
  <p>Date:Wed, 07 Mar 2018 21:32:52 GMT</p>
  
  <p>Server:Apache-Coyote/1.1</p>
  
  <p><strong>Error message (Chrome's console)</strong>:</p>
  
  <p>Failed to load <a href="http://localhost:8080/po27/api/login" rel="nofollow noreferrer">http://localhost:8080/po27/api/login</a>: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin '<a href="http://localhost:8100" rel="nofollow noreferrer">http://localhost:8100</a>' is therefore not allowed access.</p>
  
  <p>Don't think it matters but: the request is being made with Angular 4's HttpService</p>