Ensure correct scope is used when ids is empty

When an empty set of ids was specified, the mongoid scope was matching all needs instead of none as it should have been. To get Mongoid to do the right thing, we pass in [nil] when ids is empty.