Bug 36877 - Web inspector will only display cookies for (file|http[s]?) resources
Summary: Web inspector will only display cookies for (file|http[s]?) resources
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-31 02:23 PDT by Mattias Nissler
Modified: 2010-03-31 07:45 PDT (History)
3 users (show)

See Also:


Attachments
Patch (3.08 KB, patch)
2010-03-31 02:33 PDT, Mattias Nissler
no flags Details | Formatted Diff | Diff
patch (3.06 KB, patch)
2010-03-31 06:07 PDT, Mattias Nissler
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mattias Nissler 2010-03-31 02:23:10 PDT
Currently, web inspector explicitly filters the resource URLs it will display cookies for to only include file, http and https URLs. Thus, when using the inspector on some other resource (e.g. a chrome extension), it won't display any cookies even if there are some.
Comment 1 Mattias Nissler 2010-03-31 02:33:02 PDT
Created attachment 52146 [details]
Patch
Comment 2 Pavel Feldman 2010-03-31 04:55:42 PDT
Comment on attachment 52146 [details]
Patch

> +            this._addCookieDomain(match[2] ? match[2] : "");
>          }

I think you can simplify it even further due to

(match[2] ? match[2] : "") === match[2]
Comment 3 Mattias Nissler 2010-03-31 06:07:28 PDT
Created attachment 52154 [details]
patch
Comment 4 Mattias Nissler 2010-03-31 06:08:50 PDT
(In reply to comment #2)
> I think you can simplify it even further due to
> 
> (match[2] ? match[2] : "") === match[2]

Considering that a successful match of the regex always gives us a defined match[2], that's correct. Didn't think of that, thanks.(In reply to comment #2)
Comment 5 WebKit Commit Bot 2010-03-31 07:45:36 PDT
Comment on attachment 52154 [details]
patch

Clearing flags on attachment: 52154

Committed r56840: <http://trac.webkit.org/changeset/56840>
Comment 6 WebKit Commit Bot 2010-03-31 07:45:41 PDT
All reviewed patches have been landed.  Closing bug.