Skip to content

Commit 2794a8b

Browse files
author
Andrew J Westlake
committed
Fixed formatting problems
1 parent b5ec64f commit 2794a8b

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

src/generic.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,7 @@ where
114114
}
115115

116116
fn cancelled(future: &PyAny) -> PyResult<bool> {
117-
future.getattr("cancelled")?
118-
.call0()?
119-
.is_true()
117+
future.getattr("cancelled")?.call0()?.is_true()
120118
}
121119

122120
fn set_result(py: Python, future: &PyAny, result: PyResult<PyObject>) -> PyResult<()> {
@@ -222,12 +220,12 @@ where
222220
Python::with_gil(move |py| {
223221
if cancelled(future_tx1.as_ref(py))
224222
.map_err(dump_err(py))
225-
.unwrap_or(false) {
223+
.unwrap_or(false)
224+
{
226225
return;
227226
}
228227

229-
let _ = set_result(py, future_tx1.as_ref(py), result)
230-
.map_err(dump_err(py));
228+
let _ = set_result(py, future_tx1.as_ref(py), result).map_err(dump_err(py));
231229
});
232230
})
233231
.await
@@ -236,7 +234,8 @@ where
236234
Python::with_gil(move |py| {
237235
if cancelled(future_tx2.as_ref(py))
238236
.map_err(dump_err(py))
239-
.unwrap_or(false) {
237+
.unwrap_or(false)
238+
{
240239
return;
241240
}
242241

@@ -343,12 +342,12 @@ where
343342
Python::with_gil(move |py| {
344343
if cancelled(future_tx1.as_ref(py))
345344
.map_err(dump_err(py))
346-
.unwrap_or(false) {
345+
.unwrap_or(false)
346+
{
347347
return;
348348
}
349349

350-
let _ = set_result(py, future_tx1.as_ref(py), result)
351-
.map_err(dump_err(py));
350+
let _ = set_result(py, future_tx1.as_ref(py), result).map_err(dump_err(py));
352351
});
353352
})
354353
.await
@@ -357,7 +356,8 @@ where
357356
Python::with_gil(move |py| {
358357
if cancelled(future_tx2.as_ref(py))
359358
.map_err(dump_err(py))
360-
.unwrap_or(false) {
359+
.unwrap_or(false)
360+
{
361361
return;
362362
}
363363

0 commit comments

Comments
 (0)