Minor refactoring for ContentController::getEntries()