Skip to content

Commit

Permalink
webdriver: Fix parsing of FrameIds with Elements
Browse files Browse the repository at this point in the history
Source-Repo: https://github.com/mozilla/webdriver-rust
Source-Revision: f0168a1510f08990dc5394050adade86dc548944

--HG--
extra : subtree_source : http%3A//tristan.corp.lon2.mozilla.com%3A8000
extra : subtree_revision : a62404c8c6d39bb7d4cf79f3f79d4f53da98af31
  • Loading branch information
jgraham committed Mar 6, 2015
1 parent fe1a9ec commit 07f2922
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion testing/webdriver/src/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,8 @@ impl FrameId {
Ok(FrameId::Short(id))
},
&Json::Null => Ok(FrameId::Null),
&Json::String(ref x) => Ok(FrameId::Element(WebElement::new(x.clone()))),
&Json::Object(_) => Ok(FrameId::Element(
try!(WebElement::from_json(data)))),
_ => Err(WebDriverError::new(ErrorStatus::NoSuchFrame,
"frame id has unexpected type"))
}
Expand Down

0 comments on commit 07f2922

Please sign in to comment.