Fix potential FileNotFoundException with config files