Small fixes during initial scan of document