From 3f5b74247dd19dfa7d509ed567340b5bdd6d07d0 Mon Sep 17 00:00:00 2001 From: Gijs van Veen Date: Tue, 14 Jun 2022 11:12:51 +0200 Subject: [PATCH] Fixed issues --- stencils/KalugaDate+Extensions.stencil | 2 +- stencils/UninitializedSubject.stencil | 9 +-------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/stencils/KalugaDate+Extensions.stencil b/stencils/KalugaDate+Extensions.stencil index d50daaa..96de5ae 100644 --- a/stencils/KalugaDate+Extensions.stencil +++ b/stencils/KalugaDate+Extensions.stencil @@ -1,7 +1,7 @@ import Foundation import {{ argument.sharedFrameworkName }} -typealias KalugaDate = {{ argument.sharedFrameworkName }}.Date +typealias KalugaDate = {{ argument.sharedFrameworkName }}.KalugaDate typealias DefaultKalugaDate = {{ argument.sharedFrameworkName }}.DefaultKalugaDate extension Foundation.Date { diff --git a/stencils/UninitializedSubject.stencil b/stencils/UninitializedSubject.stencil index 7249210..aed8073 100644 --- a/stencils/UninitializedSubject.stencil +++ b/stencils/UninitializedSubject.stencil @@ -28,14 +28,7 @@ class UninitializedSubject: ObservableObject { value = toMapper(input!) } cancellable = _value.projectedValue.sink { newValue in - if let current = subject.currentOrNull, newValue == toMapper(current) { - return - } - if let newValue = newValue { - subject.post(newValue: fromMapper(newValue)) - } else { - subject.post(newValue: nil) - } + subject.post(newValue: fromMapper(newValue)) } subject .observe { [weak self] newValue in