save to db after saving