git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-3026 fixes MigLayout, JSON parser
[jalview.git]
/
src
/
jalview
/
javascript
/
web
/
ClientResponse.java
diff --git
a/src/jalview/javascript/web/ClientResponse.java
b/src/jalview/javascript/web/ClientResponse.java
index
e33dd98
..
66a1b19
100644
(file)
--- a/
src/jalview/javascript/web/ClientResponse.java
+++ b/
src/jalview/javascript/web/ClientResponse.java
@@
-6,9
+6,9
@@
public class ClientResponse
{
private String response;
{
private String response;
- private String encoding;
+ private String[] encoding;
- public ClientResponse(String response, String encoding)
+ public ClientResponse(String response, String... encoding)
{
this.response = response;
this.encoding = encoding;
{
this.response = response;
this.encoding = encoding;
@@
-47,7
+47,7
@@
public class ClientResponse
public int getStatus()
{
// note, we could get the actual response. I am just assuming it is 200 or 400
public int getStatus()
{
// note, we could get the actual response. I am just assuming it is 200 or 400
- return (response != null && (response.startsWith("{") == encoding.equals("application/json"))
+ return (response != null && (response.startsWith("{") == encoding[0].equals("application/json"))
? 200 : 400);
}
? 200 : 400);
}