mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Add plugins for compositing and net crates #7699
Changed to_string calls to to_owned calls where was a need.
This commit is contained in:
parent
44de9173cc
commit
88815d21ba
18 changed files with 43 additions and 31 deletions
|
@ -41,7 +41,7 @@ pub fn load(load_data: LoadData, start_chan: LoadConsumer) {
|
|||
let parts: Vec<&str> = scheme_data.splitn(2, ',').collect();
|
||||
if parts.len() != 2 {
|
||||
start_sending(start_chan,
|
||||
metadata).send(Done(Err("invalid data uri".to_string()))).unwrap();
|
||||
metadata).send(Done(Err("invalid data uri".to_owned()))).unwrap();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -68,7 +68,7 @@ pub fn load(load_data: LoadData, start_chan: LoadConsumer) {
|
|||
let bytes = bytes.into_iter().filter(|&b| b != ' ' as u8).collect::<Vec<u8>>();
|
||||
match bytes.from_base64() {
|
||||
Err(..) => {
|
||||
progress_chan.send(Done(Err("non-base64 data uri".to_string()))).unwrap();
|
||||
progress_chan.send(Done(Err("non-base64 data uri".to_owned()))).unwrap();
|
||||
}
|
||||
Ok(data) => {
|
||||
progress_chan.send(Payload(data)).unwrap();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue