Small cleaning and db save added