Skip to content

Commit

Permalink
Use withValue(action:) in value.getter.
Browse files Browse the repository at this point in the history
  • Loading branch information
andersio committed Dec 20, 2015
1 parent 6df2342 commit 8936304
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions ReactiveCocoa/Swift/Property.swift
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,7 @@ public final class MutableProperty<Value>: MutablePropertyType {
/// created from the `values` producer.
public var value: Value {
get {
lock.lock()
defer { lock.unlock() }

return _value
return withValue { $0 }
}

set {
Expand Down

0 comments on commit 8936304

Please sign in to comment.