Fix trying to unwrap documents that aren't supposed to be unwrapped