| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 699 */ | 699 */ |
| 700 _headerValue: function(headers, headerName) | 700 _headerValue: function(headers, headerName) |
| 701 { | 701 { |
| 702 headerName = headerName.toLowerCase(); | 702 headerName = headerName.toLowerCase(); |
| 703 | 703 |
| 704 var values = []; | 704 var values = []; |
| 705 for (var i = 0; i < headers.length; ++i) { | 705 for (var i = 0; i < headers.length; ++i) { |
| 706 if (headers[i].name.toLowerCase() === headerName) | 706 if (headers[i].name.toLowerCase() === headerName) |
| 707 values.push(headers[i].value); | 707 values.push(headers[i].value); |
| 708 } | 708 } |
| 709 if (!values.length) |
| 710 return undefined; |
| 709 // Set-Cookie values should be separated by '\n', not comma, otherwise c
ookies could not be parsed. | 711 // Set-Cookie values should be separated by '\n', not comma, otherwise c
ookies could not be parsed. |
| 710 if (headerName === "set-cookie") | 712 if (headerName === "set-cookie") |
| 711 return values.join("\n"); | 713 return values.join("\n"); |
| 712 return values.join(", "); | 714 return values.join(", "); |
| 713 }, | 715 }, |
| 714 | 716 |
| 715 /** | 717 /** |
| 716 * @return {?string|undefined} | 718 * @return {?string|undefined} |
| 717 */ | 719 */ |
| 718 get content() | 720 get content() |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 907 _pushFrame: function(object) | 909 _pushFrame: function(object) |
| 908 { | 910 { |
| 909 if (this._frames.length >= 100) { | 911 if (this._frames.length >= 100) { |
| 910 this._frames.splice(0, 10); | 912 this._frames.splice(0, 10); |
| 911 } | 913 } |
| 912 this._frames.push(object); | 914 this._frames.push(object); |
| 913 }, | 915 }, |
| 914 | 916 |
| 915 __proto__: WebInspector.Object.prototype | 917 __proto__: WebInspector.Object.prototype |
| 916 } | 918 } |
| OLD | NEW |