final Frame frame = (Frame) msg;
final ByteBuf content = Transports.wrapWithLN(frame.content());
frame.release();
final FullHttpResponse response = new DefaultFullHttpResponse(request.getProtocolVersion(), OK, content);
response.headers().set(CONTENT_TYPE, CONTENT_TYPE_JAVASCRIPT);
response.headers().set(CONTENT_LENGTH, content.readableBytes());
response.headers().set(CONNECTION, CLOSE);
Transports.setDefaultHeaders(response, config, request);
Transports.writeResponse(ctx, promise, response);
} else {
ctx.writeAndFlush(ReferenceCountUtil.retain(msg), promise);