From 70453737080ab46492d5d4da69d175752c619488 Mon Sep 17 00:00:00 2001 From: Mathew Polzin Date: Wed, 23 Jan 2019 23:24:53 -0800 Subject: [PATCH] update and make sure all Playground pages run --- .../Contents.swift | 1 + .../OpenAPI Documentation.xcplaygroundpage/Contents.swift | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/JSONAPI.playground/Pages/Full Client & Server Example.xcplaygroundpage/Contents.swift b/JSONAPI.playground/Pages/Full Client & Server Example.xcplaygroundpage/Contents.swift index abf3668..27ef739 100644 --- a/JSONAPI.playground/Pages/Full Client & Server Example.xcplaygroundpage/Contents.swift +++ b/JSONAPI.playground/Pages/Full Client & Server Example.xcplaygroundpage/Contents.swift @@ -1,5 +1,6 @@ import Foundation import JSONAPI +import Poly // MARK: - Preamble (setup) diff --git a/JSONAPI.playground/Pages/OpenAPI Documentation.xcplaygroundpage/Contents.swift b/JSONAPI.playground/Pages/OpenAPI Documentation.xcplaygroundpage/Contents.swift index 01cff69..a0691d7 100644 --- a/JSONAPI.playground/Pages/OpenAPI Documentation.xcplaygroundpage/Contents.swift +++ b/JSONAPI.playground/Pages/OpenAPI Documentation.xcplaygroundpage/Contents.swift @@ -15,14 +15,14 @@ print("====") print(personSchemaData.map { String(data: $0, encoding: .utf8)! } ?? "Schema Construction Failed") print("====") -let dogDocumentSchemaData = try? encoder.encode(SingleDogDocument.openAPINodeWithExample()) +let dogDocumentSchemaData = try? encoder.encode(SingleDogDocument.openAPINodeWithExample(using: encoder)) print("Dog Document Schema") print("====") print(dogDocumentSchemaData.map { String(data: $0, encoding: .utf8)! } ?? "Schema Construction Failed") print("====") -let batchPersonSchemaData = try? encoder.encode(BatchPeopleDocument.openAPINodeWithExample()) +let batchPersonSchemaData = try? encoder.encode(BatchPeopleDocument.openAPINodeWithExample(using: encoder)) print("Batch Person Document Schema") print("====")