mirror of
https://github.com/VinylDNS/vinyldns
synced 2025-08-30 13:58:15 +00:00
convert response message from json string to json
This commit is contained in:
@@ -214,12 +214,15 @@ class ZoneService(
|
||||
responseMessage: String = Source.fromInputStream(inputStream, "UTF-8").mkString
|
||||
_ <- isValidGenerateZoneConn(responseCode, responseMessage).toResult
|
||||
|
||||
// Parse response
|
||||
responseJson = parse(responseMessage)
|
||||
|
||||
// Create response object
|
||||
zoneGenerateResponse = ZoneGenerationResponse(
|
||||
provider = request.provider,
|
||||
responseCode = responseCode,
|
||||
status = dnsConnResponse.getResponseMessage,
|
||||
message = responseMessage
|
||||
message = responseJson
|
||||
)
|
||||
|
||||
// Save to repository
|
||||
|
@@ -249,7 +249,7 @@ case class ZoneGenerationResponse(
|
||||
provider: String,
|
||||
responseCode: Int,
|
||||
status: String,
|
||||
message: String
|
||||
message: JValue
|
||||
)
|
||||
|
||||
case class ZoneGenerationInput(
|
||||
|
@@ -224,7 +224,7 @@ trait ProtobufConversions {
|
||||
zgr.getProvider,
|
||||
zgr.getResponseCode.toInt,
|
||||
zgr.getStatus,
|
||||
zgr.getMessage
|
||||
parse(zgr.getMessage)
|
||||
)
|
||||
|
||||
def fromPB(rd: VinylDNSProto.RecordData, rt: RecordType): RecordData =
|
||||
@@ -533,7 +533,7 @@ trait ProtobufConversions {
|
||||
.setProvider(zgr.provider)
|
||||
.setResponseCode(zgr.responseCode.toLong)
|
||||
.setStatus(zgr.status)
|
||||
.setMessage(zgr.message)
|
||||
.setMessage(compact(render(zgr.message)))
|
||||
.build()
|
||||
|
||||
def fromPB(data: VinylDNSProto.User): User =
|
||||
|
Reference in New Issue
Block a user