Skip to content

Commit f5664ea

Browse files
committed
SD image requests - adding logging for testing 11
1 parent 414d38d commit f5664ea

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

java/sage/MetaImage.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3270,7 +3270,7 @@ private boolean loadCacheFile()
32703270
HttpURLConnection httpConn = (HttpURLConnection) myURLConn;
32713271
if (isSDURL) {
32723272
if (Sage.DBG) System.out.println("MetaImage.loadCacheFile: HttpURLConnection response found for SD image - type:" + httpConn.getContentType() + " response code:" + httpConn.getResponseCode());
3273-
if (httpConn.getContentType()=="application/json"){
3273+
if ("application/json".equals(httpConn.getContentType())){
32743274
//SD returned an error which is within the returned json
32753275
//TODO: remove after testing
32763276
if (Sage.DBG) System.out.println("MetaImage.loadCacheFile: Prior to ErrorHandling");

java/sage/epg/sd/SDUtils.java

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,11 @@ public static void handleSDJsonErrorFromHttpResponse(HttpURLConnection httpConn)
9999

100100
if (Sage.DBG) System.out.println("SDUtils.handleSDJsonErrorFromHttpResponse: Error code:" + code);
101101

102-
SDErrors.throwErrorForCode(code);
103-
if (Sage.DBG) System.out.println("SDUtils.handleSDJsonErrorFromHttpResponse: AFTER throwing error for code:" + code);
102+
//SDErrors.throwErrorForCode(code);
103+
if (Sage.DBG) System.out.println("SDUtils.handleSDJsonErrorFromHttpResponse: Error:" + code + " : " + SDErrors.getErrorForCode(code));
104+
}else{
105+
if (Sage.DBG) System.out.println("SDUtils.handleSDJsonErrorFromHttpResponse: Unknown Error");
104106
}
105-
106-
if (Sage.DBG) System.out.println("SDUtils.handleSDJsonErrorFromHttpResponse: PRIOR to throwing UNKOWN");
107-
throw new SDException(SDErrors.SAGETV_UNKNOWN);
108-
109107
}
110108

111109
/**

0 commit comments

Comments
 (0)