Use weak references in KVO observation

Hopefully fixes #1206 and #1548.
There was no way to pass in a target that was already dead, since it was a strong parameter. Now that it's weak, it could possibly disappear before this line.