#fixed code
                                @Override
    public Response act(final Request req) throws IOException {
        final JsonObject callback = TkViber.json(
            new TextOf(req.body()).asString()
        );
        if (callback.isEmpty()) {
            throw new HttpException(HttpURLConnection.HTTP_BAD_REQUEST);
        }
        if (Objects.equals(callback.getString("event"), "message")) {
            this.reaction.react(
                this.bot, this.farm, new VbEvent.Simple(callback)
            );
        }
        return new RsWithStatus(
            HttpURLConnection.HTTP_OK
        );
    }
#vulnerable code 
                                @Override
    public Response act(final Request req) throws IOException {
        final JsonObject callback = TkViber.json(
            new InputStreamReader(req.body(), StandardCharsets.UTF_8)
        );
        if (callback.isEmpty()) {
            throw new HttpException(HttpURLConnection.HTTP_BAD_REQUEST);
        }
        if (Objects.equals(callback.getString("event"), "message")) {
            this.reaction.react(
                this.bot, this.farm, new VbEvent.Simple(callback)
            );
        }
        return new RsWithStatus(
            HttpURLConnection.HTTP_OK
        );
    } 
                            #location 3 
                            #vulnerability type RESOURCE_LEAK