Extract DB logic from ViewModels #13