| Index: pkg/http_parser/lib/http_parser.dart
|
| diff --git a/pkg/shelf/lib/src/util.dart b/pkg/http_parser/lib/http_parser.dart
|
| similarity index 94%
|
| copy from pkg/shelf/lib/src/util.dart
|
| copy to pkg/http_parser/lib/http_parser.dart
|
| index bf8e370804ddd81dbbdbe3f453ca760ad2372e26..3b876d09e4f0a01f29c890370c113ecb238839a1 100644
|
| --- a/pkg/shelf/lib/src/util.dart
|
| +++ b/pkg/http_parser/lib/http_parser.dart
|
| @@ -2,15 +2,11 @@
|
| // for details. All rights reserved. Use of this source code is governed by a
|
| // BSD-style license that can be found in the LICENSE file.
|
|
|
| -library shelf.util;
|
| +library http_parser;
|
|
|
| -import 'dart:async';
|
| -
|
| -import 'package:stack_trace/stack_trace.dart';
|
| import 'package:string_scanner/string_scanner.dart';
|
|
|
| -/// Like [Future.sync], but wraps the Future in [Chain.track] as well.
|
| -Future syncFuture(callback()) => Chain.track(new Future.sync(callback));
|
| +export 'src/media_type.dart';
|
|
|
| const _WEEKDAYS = const ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"];
|
| const _MONTHS = const ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug",
|
| @@ -122,9 +118,9 @@ int _parseInt(StringScanner scanner, int digits) {
|
| scanner.expect(_digitRegExp);
|
| if (scanner.lastMatch[0].length != digits) {
|
| scanner.error("expected a $digits-digit number.");
|
| - } else {
|
| - return int.parse(scanner.lastMatch[0]);
|
| }
|
| +
|
| + return int.parse(scanner.lastMatch[0]);
|
| }
|
|
|
| /// Parses an timestamp of the form "HH:MM:SS" on a 24-hour clock.
|
|
|