commit
7467ca8752
1 changed files with 6 additions and 1 deletions
|
@ -129,7 +129,12 @@ public class OsmBugsRemoteUtil implements OsmBugsUtil {
|
||||||
log.info(msg); //$NON-NLS-1$
|
log.info(msg); //$NON-NLS-1$
|
||||||
// populate return fields.
|
// populate return fields.
|
||||||
|
|
||||||
StringBuilder responseBody = Algorithms.readFromInputStream(connection.getInputStream());
|
StringBuilder responseBody;
|
||||||
|
if (connection.getResponseCode() == HttpURLConnection.HTTP_CONFLICT) {
|
||||||
|
responseBody = Algorithms.readFromInputStream(connection.getErrorStream());
|
||||||
|
} else {
|
||||||
|
responseBody = Algorithms.readFromInputStream(connection.getInputStream());
|
||||||
|
}
|
||||||
log.info("Response : " + responseBody); //$NON-NLS-1$
|
log.info("Response : " + responseBody); //$NON-NLS-1$
|
||||||
connection.disconnect();
|
connection.disconnect();
|
||||||
if (!ok) {
|
if (!ok) {
|
||||||
|
|
Loading…
Reference in a new issue