adding localDataBase functionalities, need to adapt synchronization functions