Fixed settings path to write a file