Accept consent issue

I am having an error when I am calling this endpoint “/consent/<consent_challenge>/accept”

Error details below:

time=“2018-12-14T21:52:43Z” level=error msg=“An error occurred while handling a request” code=400 details=“map[]” error=“pq: duplicate key value violates unique constraint “hydra_oauth2_consent_request_handled_pkey”: Unable to insert row because a column value is not unique” reason= request-id= status=“Bad Request”

This happens when you send this request twice, or when the consent challenge has been accepted already.