From ab21b839ef1a68468024f26dcf56b6c4598eb6c2 Mon Sep 17 00:00:00 2001 From: Ian Dundas Date: Thu, 6 Aug 2015 23:34:23 +0200 Subject: [PATCH] Fixed Typo & BehaviorSubject's description in Subjects Playground Note - BehaviorSubject still also needs a description (seems to be copy pasted from ReplaySubject) --- Playgrounds/Subjects.playground/Contents.swift | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Playgrounds/Subjects.playground/Contents.swift b/Playgrounds/Subjects.playground/Contents.swift index c543e9d9..5a64d769 100644 --- a/Playgrounds/Subjects.playground/Contents.swift +++ b/Playgrounds/Subjects.playground/Contents.swift @@ -55,10 +55,9 @@ example("ReplaySubject") { ## BehaviorSubject a.k.a. Variable -ReplaySubject emits to any observer all of the items, in the buffer, that were emitted by the source - +BehaviorSubject is similar to ReplaySubject except it only remembers the last item. This means that all subscribers will receive a value immediately (unless it is already completed). */ -example("ReplaySubject") { +example("BehaviorSubject") { let subject = BehaviorSubject(value: "z") writeSequenceToConsole("1", subject) sendNext(subject, "a")