Ver a proveniência

Fix response from debug echo call

pull/16/head
Kristijan Mitrovic há 4 anos
ascendente
cometimento
68b39f32d7
1 ficheiros alterados com 3 adições e 4 eliminações
  1. +3
    -4
      bubble-server/src/main/java/bubble/resources/DebugResource.java

+ 3
- 4
bubble-server/src/main/java/bubble/resources/DebugResource.java Ver ficheiro

@@ -37,8 +37,7 @@ import static bubble.cloud.auth.RenderedMessage.filteredInbox;
import static org.cobbzilla.util.daemon.ZillaRuntime.die;
import static org.cobbzilla.util.daemon.ZillaRuntime.empty;
import static org.cobbzilla.util.http.HttpContentTypes.APPLICATION_JSON;
import static org.cobbzilla.util.json.JsonUtil.findNode;
import static org.cobbzilla.util.json.JsonUtil.toJsonOrDie;
import static org.cobbzilla.util.json.JsonUtil.*;
import static org.cobbzilla.util.reflect.ReflectionUtil.forName;
import static org.cobbzilla.util.reflect.ReflectionUtil.instantiate;
import static org.cobbzilla.wizard.resources.ResourceUtil.*;
@@ -131,9 +130,9 @@ public class DebugResource {
final var output = "ECHO: \n" + toJsonOrDie(input);
log.info(output);

if (empty(respondWith)) return ok(output + "\n");
if (empty(respondWith)) return ok();

log.debug("Responding with value in path: " + respondWith);
return ok(findNode(input, respondWith));
return ok(getNodeAsJava(findNode(input, respondWith), ""));
}
}

Carregando…
Cancelar
Guardar