from domains.historique import HistoriqueSynchronisation
from config import config


class ImplementationHistorique(HistoriqueSynchronisation):

    def save_synchronisation(self):
        try:
            with open(config.history_file, "a") as history:
                history.write(self.date + "," + self.synchro_message + "\n")
                history.close()
                return True
        except Exception as e:
            print(e)
            return False
