Chromium Code Reviews| Index: third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp |
| diff --git a/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp b/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp |
| index c5226b152dd05baaba5ee5986703f0d1dbfdcc0f..1fdf12d99f7a2c5b0e1e647d8dbd631241599ed4 100644 |
| --- a/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp |
| +++ b/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp |
| @@ -70,7 +70,8 @@ PresentationRequest* PresentationRequest::create( |
| const String& url, |
| ExceptionState& exceptionState) { |
| KURL parsedUrl = KURL(executionContext->url(), url); |
| - if (!parsedUrl.isValid() || parsedUrl.protocolIsAbout()) { |
| + if (!parsedUrl.isValid() || !parsedUrl.protocolIsInHTTPFamily() || |
|
zhaobin
2016/12/09 18:53:02
Remove parsedUrl.protocolIsAbout() check if we alr
CJ
2016/12/13 02:12:38
I'm not seeing how they overlap with each other. P
zhaobin
2016/12/13 19:06:02
!protocolIsInHTTPFamily() means not http or https.
CJ
2016/12/13 21:34:23
Done.
|
| + parsedUrl.protocolIsAbout()) { |
| exceptionState.throwTypeError("'" + url + |
| "' can't be resolved to a valid URL."); |
| return nullptr; |