Skip to content

Commit

Permalink
refactor: use fs/promises (#1445)
Browse files Browse the repository at this point in the history
  • Loading branch information
dnalborczyk authored May 21, 2022
1 parent 1e9445e commit 969b37c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/ServerlessOffline.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import process, { env, exit } from 'node:process'
import updateNotifier from 'update-notifier'
import chalk from 'chalk'
import { parse as semverParse } from 'semver'
import updateNotifier from 'update-notifier'
import debugLog from './debugLog.js'
import serverlessLog, { logWarning, setLog } from './serverlessLog.js'
import { satisfiesVersionRange } from './utils/index.js'
Expand Down
3 changes: 2 additions & 1 deletion src/lambda/LambdaFunction.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { readFile, writeFile } from 'node:fs/promises'
import { dirname, join, resolve } from 'node:path'
import { performance } from 'node:perf_hooks'
import { emptyDir, ensureDir, readFile, remove, writeFile } from 'fs-extra'
import { emptyDir, ensureDir, remove } from 'fs-extra'
import jszip from 'jszip'
import HandlerRunner from './handler-runner/index.js'
import LambdaContext from './LambdaContext.js'
Expand Down
3 changes: 2 additions & 1 deletion src/lambda/handler-runner/docker-runner/DockerContainer.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { createHash } from 'node:crypto'
import { createWriteStream, unlinkSync } from 'node:fs'
import { readFile, writeFile } from 'node:fs/promises'
import { platform } from 'node:os'
import { dirname, join, sep } from 'node:path'
import { Lambda } from 'aws-sdk'
import execa from 'execa'
import { ensureDir, pathExists, readFile, writeFile } from 'fs-extra'
import { ensureDir, pathExists } from 'fs-extra'
import jszip from 'jszip'
import fetch from 'node-fetch'
import pRetry from 'p-retry'
Expand Down

0 comments on commit 969b37c

Please sign in to comment.