From 8084177bdacd71bcd775d78d1f48386255e15f99 Mon Sep 17 00:00:00 2001 From: Robbert Brandsma Date: Thu, 28 Mar 2019 11:50:38 +0100 Subject: [PATCH] Loosen requirement of `update` on `Decoder` from `QueryableModel` to `KeyPathQueryable` --- Sources/Meow/Updatable.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/Meow/Updatable.swift b/Sources/Meow/Updatable.swift index 36179e5..bc54489 100644 --- a/Sources/Meow/Updatable.swift +++ b/Sources/Meow/Updatable.swift @@ -80,7 +80,7 @@ extension WritableKeyPath: OptionalKeyPath where Value: ExpressibleByNilLiteral public extension Decoder { /// - returns: An array containing the key paths that were updated - public func update(_ instance: T, withAllowedKeyPaths keyPaths: [MeowWritableKeyPath]) throws -> [PartialKeyPath] { + public func update(_ instance: T, withAllowedKeyPaths keyPaths: [MeowWritableKeyPath]) throws -> [PartialKeyPath] { let container = try self.container(keyedBy: UpdateCodingKey.self) // must pass as inout to the KeyPath, hence the var