Commit a88cc28c authored by Mikhail Pozdnyakov's avatar Mikhail Pozdnyakov Committed by Commit Bot

[sensors] Remove the redundant security context check

As it follows from https://github.com/w3c/sensors/pull/315

Change-Id: I6e2adaae43153fdff3cb792f7e9741652f12f9c0
Reviewed-on: https://chromium-review.googlesource.com/725326Reviewed-by: default avatarAlexander Shalamov <alexander.shalamov@intel.com>
Commit-Queue: Mikhail Pozdnyakov <mikhail.pozdnyakov@intel.com>
Cr-Commit-Position: refs/heads/master@{#509747}
parent 739fd18d
...@@ -30,12 +30,8 @@ Sensor::Sensor(ExecutionContext* execution_context, ...@@ -30,12 +30,8 @@ Sensor::Sensor(ExecutionContext* execution_context,
type_(type), type_(type),
state_(SensorState::kIdle), state_(SensorState::kIdle),
last_reported_timestamp_(0.0) { last_reported_timestamp_(0.0) {
// Check secure context. // [SecureContext] in idl.
String error_message; DCHECK(execution_context->IsSecureContext());
if (!execution_context->IsSecureContext(error_message)) {
exception_state.ThrowSecurityError(error_message);
return;
}
// Check top-level browsing context. // Check top-level browsing context.
if (!ToDocument(execution_context)->domWindow()->GetFrame() || if (!ToDocument(execution_context)->domWindow()->GetFrame() ||
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment