Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(591)

Unified Diff: utils/pub/source.dart

Issue 11369066: Show better error messages in network failures. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: utils/pub/source.dart
diff --git a/utils/pub/source.dart b/utils/pub/source.dart
index bb956c95c106916c1979ae8c89814173beb543b5..8c54b73bad4487aff7a1fee0700794154599cea9 100644
--- a/utils/pub/source.dart
+++ b/utils/pub/source.dart
@@ -23,6 +23,9 @@ abstract class Source {
*/
abstract String get name;
+ /// Whether or not this source is the default source.
+ bool get isDefault => systemCache.sources.defaultSource == this;
+
/**
* Whether this source's packages should be cached in Pub's global cache
* directory.

Powered by Google App Engine
This is Rietveld 408576698