@pi-r/rollup 0.10.4 → 0.10.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +4 -4
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -14,7 +14,10 @@ const PLUGIN_MAP = Object.freeze({
14
14
  '@rollup/plugin-node-resolve': nodeResolve
15
15
  });
16
16
  function getPlugins(plugin) {
17
- return plugin && !Array.isArray(plugin) ? [plugin] : [];
17
+ if (plugin) {
18
+ return !Array.isArray(plugin) ? [plugin] : plugin;
19
+ }
20
+ return [];
18
21
  }
19
22
  async function transform(context, value, options) {
20
23
  context = options.upgrade(context, __dirname);
@@ -187,9 +190,6 @@ async function transform(context, value, options) {
187
190
  for (const file of tmp) {
188
191
  fs.unlink(file, () => { });
189
192
  }
190
- if (tempDir) {
191
- fs.rm(tempDir, { recursive: true, force: true }, () => { });
192
- }
193
193
  });
194
194
  }
195
195
  if (result) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pi-r/rollup",
3
- "version": "0.10.4",
3
+ "version": "0.10.6",
4
4
  "description": "Rollup transform function for E-mc.",
5
5
  "main": "index.js",
6
6
  "publishConfig": {