do only compress gpx/json
This commit is contained in:
parent
bcf6a7f630
commit
158dc5e54d
1 changed files with 1 additions and 1 deletions
|
@ -100,7 +100,7 @@ public class BRouterService extends Service {
|
|||
boolean canCompress = "true".equals(params.getString("acceptCompressedResult"));
|
||||
try {
|
||||
String gpxMessage = worker.getTrackFromParams(params);
|
||||
if (canCompress) {
|
||||
if (canCompress && (gpxMessage.startsWith("<") || gpxMessage.startsWith("{"))) {
|
||||
try {
|
||||
ByteArrayOutputStream baos = new ByteArrayOutputStream();
|
||||
baos.write("z64".getBytes(Charset.forName("UTF-8"))); // marker prefix
|
||||
|
|
Loading…
Reference in a new issue