Skip to content

Commit

Permalink
refactor: nothing
Browse files Browse the repository at this point in the history
  • Loading branch information
seognil committed Apr 11, 2020
1 parent 251c931 commit b9cd7ee
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions js/async-programming/parallel/parallel-limit-version-2.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { delay } from '../util/delay';

type AsyncFunction = () => Promise<unknown>;
const limitOf = (max: number) => {
const mq: AsyncFunction[] = [];
Expand All @@ -26,6 +24,8 @@ const limitOf = (max: number) => {

// * ================================================================================

import { delay } from '../util/delay';

const limit = limitOf(2);

console.warn('start');
Expand Down
4 changes: 2 additions & 2 deletions js/async-programming/parallel/parallel-limit.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { delay } from '../util/delay';

type AsyncFunction = () => Promise<unknown>;

const limitOf = (max: number) => {
Expand All @@ -20,6 +18,8 @@ const limitOf = (max: number) => {

// * ================================================================================

import { delay } from '../util/delay';

const limit = limitOf(2);

for (let i = 1; i < 10; i++) {
Expand Down

0 comments on commit b9cd7ee

Please sign in to comment.