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

Unified Diff: pkg/docgen/lib/src/models/library.dart

Issue 304203004: Correctly handle case where we have a library outside of a package. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 months 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: pkg/docgen/lib/src/models/library.dart
diff --git a/pkg/docgen/lib/src/models/library.dart b/pkg/docgen/lib/src/models/library.dart
index 826536fb1bfe86574e392c8774d3a4e22445c330..ccd12a22b7c07773298be38c2ba46bb35415272a 100644
--- a/pkg/docgen/lib/src/models/library.dart
+++ b/pkg/docgen/lib/src/models/library.dart
@@ -142,6 +142,8 @@ class Library extends Indexable {
if (packageIntro != null) {
map['packageIntro'] = packageIntro;
}
+ var version = packageVersion(mirror);
+ if (version != '' && version != null) map['version'] = version;
return map;
}

Powered by Google App Engine
This is Rietveld 408576698