Chromium Code Reviews| Index: lib/src/server/server.dart |
| diff --git a/lib/src/server/server.dart b/lib/src/server/server.dart |
| index 13b9b244df75428328f5d5dd789545f4d92c2f16..0a15d2d15dfc02b51a060a22e9dd7cf3a4a839c8 100644 |
| --- a/lib/src/server/server.dart |
| +++ b/lib/src/server/server.dart |
| @@ -246,7 +246,7 @@ class DevServer { |
| ? SourceResolverOptions.implicitHtmlFile |
| : entryPath; |
| - Future<bool> start() async { |
| + Future start() async { |
| // Create output directory if needed. shelf_static will fail otherwise. |
| var out = new Directory(outDir); |
| if (!await out.exists()) await out.create(recursive: true); |
| @@ -257,8 +257,7 @@ class DevServer { |
| defaultDocument: _entryPath)); |
| await shelf.serve(handler, host, port); |
| print('Serving $_entryPath at http://$host:$port/'); |
| - CheckerResults results = compiler.run(); |
| - return !results.failure; |
| + // Never returns |
|
Leaf
2015/08/04 22:27:59
I don't follow this comment. Does shelf.serve nev
Jennifer Messerly
2015/08/04 22:41:36
Good catch, the comment is wrong. Removed. Also re
|
| } |
| shelf.Handler rebuildAndCache(shelf.Handler handler) => (request) { |
| @@ -285,11 +284,11 @@ class DevServer { |
| } |
| UriResolver _createImplicitEntryResolver(String entryPath) { |
| - var entry = path.absolute(SourceResolverOptions.implicitHtmlFile); |
| - var src = path.absolute(entryPath); |
| + var entry = path.toUri(path.absolute(SourceResolverOptions.implicitHtmlFile)); |
| + var src = path.toUri(path.absolute(entryPath)); |
| var provider = new MemoryResourceProvider(); |
| provider.newFile( |
| - entry, '<body><script type="application/dart" src="$src"></script>'); |
| + entry.path, '<body><script type="application/dart" src="$src"></script>'); |
| return new _ExistingSourceUriResolver(new ResourceUriResolver(provider)); |
| } |