slush-vertx icon indicating copy to clipboard operation
slush-vertx copied to clipboard

Code generated for binary string file upload has syntax errors

Open InfoSec812 opened this issue 5 years ago • 6 comments

For the following example snippet of OpenAPI spec:

    post:
      security:
      - ApiKeyAuth: []
      - BearerAuth: []
      description: Upload a new photo and get back the unique identifier
      operationId: addPhoto
      requestBody:
        content:
          image/*:
            schema:
              type: string
              format: binary

The generated method has syntax errors:

    /**
     * Call addPhoto with image/* buffer body. 
     * 
     * @param buffer Buffer that represents the body of the request
     * @param handler The handler for the asynchronous request
     */
    public void addPhotoWithImage*Buffer(
        Buffer buffer, Handler<AsyncResult<HttpResponse>> handler) {

Not sure what that should actually be. Probably a method which takes a Buffer as a parameter.

InfoSec812 avatar Dec 19 '18 18:12 InfoSec812