Various structural updates.
Check for file existence using normal code flow, rather than code contracts.
Restored the previous version.