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

Side by Side Diff: lib/src/handlers/logger.dart

Issue 1583683002: Get rid of all the library tags. (Closed) Base URL: git@github.com:dart-lang/shelf@master
Patch Set: Created 4 years, 11 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 unified diff | Download patch
« no previous file with comments | « lib/src/handler.dart ('k') | lib/src/hijack_exception.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 shelf.handlers.logger;
6
7 import 'dart:async'; 5 import 'dart:async';
8 6
9 import 'package:stack_trace/stack_trace.dart'; 7 import 'package:stack_trace/stack_trace.dart';
10 8
11 import '../hijack_exception.dart'; 9 import '../hijack_exception.dart';
12 import '../middleware.dart'; 10 import '../middleware.dart';
13 11
14 /// Middleware which prints the time of the request, the elapsed time for the 12 /// Middleware which prints the time of the request, the elapsed time for the
15 /// inner handlers, the response's status code and the request URI. 13 /// inner handlers, the response's status code and the request URI.
16 /// 14 ///
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 return '$msg\n$chain'; 74 return '$msg\n$chain';
77 } 75 }
78 76
79 void _defaultLogger(String msg, bool isError) { 77 void _defaultLogger(String msg, bool isError) {
80 if (isError) { 78 if (isError) {
81 print('[ERROR] $msg'); 79 print('[ERROR] $msg');
82 } else { 80 } else {
83 print(msg); 81 print(msg);
84 } 82 }
85 } 83 }
OLDNEW
« no previous file with comments | « lib/src/handler.dart ('k') | lib/src/hijack_exception.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698