This can all be removed. In the DFS storage system, objects can only be in packs. If the list of packs is empty, the repository is empty, and packing does not need to continue.  On a local filesystem there may be loose objects that have to be packed so this test is not enough.