Skip to content

Commit 4a1c0e9

Browse files
committed
chore: apply cargo fmt
1 parent 4a7c325 commit 4a1c0e9

2 files changed

Lines changed: 8 additions & 7 deletions

File tree

examples/custom_import_logic.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,10 @@ fn main() -> Result<(), rustyscript::Error> {
104104
// Add a redirect for a simple utility module
105105
import_provider.add_redirect("colors", "https://deno.land/std@0.224.0/fmt/colors.ts")?;
106106
// Add a static module with some test data
107-
import_provider.add_static_module("my-module", "export const foo = 1; export const bar = 'test';");
107+
import_provider.add_static_module(
108+
"my-module",
109+
"export const foo = 1; export const bar = 'test';",
110+
);
108111

109112
let mut runtime = Runtime::new(RuntimeOptions {
110113
import_provider: Some(Box::new(import_provider)),

src/ext/broadcast_channel/wrapper.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -277,9 +277,8 @@ mod test {
277277
let tokio_rt = runtime.tokio_runtime();
278278
tokio_rt.block_on(async {
279279
// Send from wrapper1
280-
let send_result: Result<(), crate::Error> = wrapper1
281-
.send::<&str>(&mut runtime, "hello from rust")
282-
.await;
280+
let send_result: Result<(), crate::Error> =
281+
wrapper1.send::<&str>(&mut runtime, "hello from rust").await;
283282
send_result.unwrap();
284283

285284
// Receive from wrapper2
@@ -318,9 +317,8 @@ mod test {
318317
let tokio_rt = runtime.tokio_runtime();
319318
tokio_rt.block_on(async {
320319
// Send to channel_a
321-
let send_result: Result<(), crate::Error> = wrapper_a
322-
.send::<&str>(&mut runtime, "message for a")
323-
.await;
320+
let send_result: Result<(), crate::Error> =
321+
wrapper_a.send::<&str>(&mut runtime, "message for a").await;
324322
send_result.unwrap();
325323

326324
// wrapper_b should not receive this message (different channel name)

0 commit comments

Comments
 (0)