Skip to content

Commit

Permalink
Replace usage of Foundation.Data with AWSBase64Data (#49)
Browse files Browse the repository at this point in the history
* Use AWSBlob instead of Data

* Replace AWSBlob with AWSBase64Data
  • Loading branch information
adam-fowler authored May 16, 2022
1 parent 58a13d3 commit b36097a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Sources/SotoCodeGeneratorLib/Smithy+CodeGeneration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ extension MemberShape {
return "String"
} else if memberShape is BlobShape {
if self.hasTrait(type: HttpPayloadTrait.self) { return "AWSPayload" }
return "Data"
return "AWSBase64Data"
} else if memberShape is CollectionShape {
return self.target.shapeName.toSwiftClassCase()
} else if let listShape = memberShape as? ListShape {
Expand All @@ -124,7 +124,7 @@ extension MemberShape {
return "String"
} else if memberShape is BlobShape {
if self.hasTrait(type: HttpPayloadTrait.self) { return "AWSPayload" }
return "Data"
return "AWSBase64Data"
} else if memberShape is CollectionShape {
return "\(withServiceName).\(self.target.shapeName.toSwiftClassCase())"
} else if let listShape = memberShape as? ListShape {
Expand Down
4 changes: 0 additions & 4 deletions Sources/SotoCodeGeneratorLib/Templates/shapes.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,7 @@ extension Templates {
{{%CONTENT_TYPE:TEXT}}
{{>header}}
#if compiler(>=5.6)
@preconcurrency import Foundation
#else
import Foundation
#endif
import SotoCore
extension {{name}} {
Expand Down

0 comments on commit b36097a

Please sign in to comment.