A new function is created and it will call saveToFile and do notification