Now using applicationDirectory variable everywhere to load files