clean code & removed loadFromFile