refactor dbCache widget