First changes for saving logs
Done some changes for storing the log messages on log file and grant that logs are added to the same log file when the app is killed, then reopened