Fix ordering behavior for scoped orderings.

Current spec status: 575 examples, 0 failures in 4.68 seconds.
Fix behavior when deleting documents.

Current spec status: 582 examples, 0 failures in 4.87 seconds.