Copy acceptsGzipEncoding method from gwtjsonrpc
This is a tiny utility that we don't need to bring in a whole external dependency for. Change-Id: I3d5d4e9f8d9272861c890ad59fca1662b05d608c
This commit is contained in:
@@ -89,5 +89,10 @@ public class RequestUtil {
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
public static boolean acceptsGzipEncoding(HttpServletRequest request) {
|
||||
String accepts = request.getHeader("Accept-Encoding");
|
||||
return accepts != null && accepts.indexOf("gzip") != -1;
|
||||
}
|
||||
|
||||
private RequestUtil() {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user