Skip to content

Commit

Permalink
feat/#95 :: Server에 Encodable Extension 추가
Browse files Browse the repository at this point in the history
- 서버에서 사용되는 Encodable Extension을 추가했습니다

Co-Authored-By: Youngkyu Song <[email protected]>
  • Loading branch information
Kiyoung-Kim-57 and youn9k committed Nov 25, 2024
1 parent ff54422 commit cbd9712
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import Foundation

extension Encodable {
func toData(_ encoder: JSONEncoder) -> Data? {
return try? encoder.encode(self)
}
}

0 comments on commit cbd9712

Please sign in to comment.