Fixed the bugs with loading Files