Commit to db after updating activities.