-
Notifications
You must be signed in to change notification settings - Fork 511
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: remove duplicate import in generated code #1043
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1043 +/- ##
==========================================
- Coverage 67.30% 67.19% -0.12%
==========================================
Files 62 62
Lines 6280 6286 +6
Branches 706 707 +1
==========================================
- Hits 4227 4224 -3
- Misses 2038 2049 +11
+ Partials 15 13 -2
... and 3 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
src/rollup/plugins/storage.ts
Outdated
@@ -24,7 +24,6 @@ export function storage(nitro: Nitro) { | |||
const driverImports = [...new Set(mounts.map((m) => m.driver))]; | |||
|
|||
const bundledStorageCode = ` | |||
import { prefixStorage } from 'unstorage' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we might remove from other place as only prefixStorage usage is now here
Thanks! |
π Linked issue
β Type of change
π Description
Small regression from #1012. We now have an import generated below:
https://github.com/unjs/nitro/blob/d8ebc8cbf1825ce12d99c98697f8a487479d4a08/src/rollup/plugins/storage.ts#L45
We can avoid the double import, which will cause a build failure whenever bundled storage is in use (e.g. nuxt/content).
π Checklist