| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library pub.command.uploader; | 5 library pub.command.uploader; |
| 6 | 6 |
| 7 import 'dart:async' hide TimeoutException; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:path/path.dart' as path; | 9 import 'package:path/path.dart' as path; |
| 10 | 10 |
| 11 import '../command.dart'; | 11 import '../command.dart'; |
| 12 import '../entrypoint.dart'; | 12 import '../entrypoint.dart'; |
| 13 import '../exit_codes.dart' as exit_codes; | 13 import '../exit_codes.dart' as exit_codes; |
| 14 import '../http.dart'; | 14 import '../http.dart'; |
| 15 import '../io.dart'; | 15 import '../io.dart'; |
| 16 import '../log.dart' as log; | 16 import '../log.dart' as log; |
| 17 import '../oauth2.dart' as oauth2; | 17 import '../oauth2.dart' as oauth2; |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 "${Uri.encodeComponent(package)}/uploaders/" | 75 "${Uri.encodeComponent(package)}/uploaders/" |
| 76 "${Uri.encodeComponent(uploader)}"); | 76 "${Uri.encodeComponent(uploader)}"); |
| 77 return client.delete(url, headers: PUB_API_HEADERS); | 77 return client.delete(url, headers: PUB_API_HEADERS); |
| 78 } | 78 } |
| 79 }); | 79 }); |
| 80 }).then(handleJsonSuccess) | 80 }).then(handleJsonSuccess) |
| 81 .catchError((error) => handleJsonError(error.response), | 81 .catchError((error) => handleJsonError(error.response), |
| 82 test: (e) => e is PubHttpException); | 82 test: (e) => e is PubHttpException); |
| 83 } | 83 } |
| 84 } | 84 } |
| OLD | NEW |