Skip to content

Commit 1ea23dd

Browse files
authored
polish(withCleanup): condense one line (#4500)
1 parent aea5175 commit 1ea23dd

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/execution/withCleanup.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,8 @@ export function withCleanup<T>(
3333
const result = await generator.next();
3434
if (result.done) {
3535
await finish();
36-
return result;
3736
}
38-
return { value: result.value, done: false };
37+
return result;
3938
} catch (error) {
4039
await finish();
4140
throw error;

0 commit comments

Comments
 (0)