mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Remove unnecessary Option.
This commit is contained in:
parent
6aacc9001b
commit
f02e516f32
6 changed files with 10 additions and 18 deletions
|
@ -75,9 +75,7 @@ impl AudioContext {
|
|||
|
||||
#[allow(unrooted_must_root)]
|
||||
pub fn new(window: &Window, options: &AudioContextOptions) -> DomRoot<AudioContext> {
|
||||
let pipeline_id = window
|
||||
.pipeline_id()
|
||||
.expect("Cannot create AudioContext outside of a pipeline");
|
||||
let pipeline_id = window.pipeline_id();
|
||||
let context = AudioContext::new_inherited(options, pipeline_id);
|
||||
let context = reflect_dom_object(Box::new(context), window, AudioContextBinding::Wrap);
|
||||
context.resume();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue