Skip to content

Commit

Permalink
Fix typo and logic
Browse files Browse the repository at this point in the history
  • Loading branch information
jfarcand committed Apr 2, 2012
1 parent 5dbcfca commit 38c330c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ private void configureStream(byte[] bytes, int offset, int length, String encodi
}
}

public boolean destroybed() {
public boolean destroyed() {
return destroyed.get();
}

Expand Down Expand Up @@ -151,7 +151,7 @@ public String getRequestedSessionId() {
*/
@Override
public String getMethod() {
return b.methodType;
return b.methodType != null ? b.methodType : b.request.getMethod();
}

/**
Expand Down Expand Up @@ -846,7 +846,7 @@ public final static class Builder {
private int offset;
private int length;
private String encoding = "UTF-8";
private String methodType = "GET";
private String methodType;
private String contentType;
private String data;
private Map<String, String> headers = new HashMap<String, String>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public void onStateChange(AtmosphereResourceEvent event)
throws IOException {

Object message = event.getMessage();
if (message == null || event.isCancelled() || event.getResource().getRequest().destroybed()) return;
if (message == null || event.isCancelled() || event.getResource().getRequest().destroyed()) return;

if (event.getResource().getSerializer() != null) {
try {
Expand Down

0 comments on commit 38c330c

Please sign in to comment.