Small refactoring in Dashboard