title: Malformed JSON response when parsing data
body: <p>Using Postman to see if this section of php works as intended, however Postman returns the error <code>Malformed JSON: Unexpected 'U'</code> and the database is not updated, can't get my head around this error as it looks fine to me?</p>
  
  <p>Code: </p>
  
  <pre><code>function placeVoteForCandidate()
  {
      global $connect;
  
      $username = $_POST["username"];
  
      $query = "UPDATE User SET votesAttained=votesAttained+1 WHERE USER_NAME = $username";
  
      mysqli_query($connect, $query) or die (mysqli_error($connect));
      mysqli_close($connect);
  
      $message['success'] = 'Vote added';
      echo json_encode($message);
  }
  </code></pre>