Adding a small if-else clause to change upload order

This is needed in order to support the strict dependency workflows
available when using Chef-Guard.