apotheke 0.1.5 → 0.1.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.
package/dist/cli.js CHANGED
@@ -392,9 +392,8 @@ function formatImports(source, config, options = {}) {
392
392
  let regionStart = firstImport.start;
393
393
  if (firstImport.attachedCommentStart !== void 0) {
394
394
  regionStart = source.lastIndexOf("\n", firstImport.attachedCommentStart) + 1;
395
- } else {
396
- regionStart = strandedHeaderStart(source, firstImport.start, headers) ?? regionStart;
397
395
  }
396
+ regionStart = strandedHeaderStart(source, regionStart, headers) ?? regionStart;
398
397
  let regionEnd = lastImport.end;
399
398
  if (source[regionEnd] === "\n") regionEnd++;
400
399
  const before = source.slice(0, regionStart);
package/dist/index.js CHANGED
@@ -389,9 +389,8 @@ function formatImports(source, config, options = {}) {
389
389
  let regionStart = firstImport.start;
390
390
  if (firstImport.attachedCommentStart !== void 0) {
391
391
  regionStart = source.lastIndexOf("\n", firstImport.attachedCommentStart) + 1;
392
- } else {
393
- regionStart = strandedHeaderStart(source, firstImport.start, headers) ?? regionStart;
394
392
  }
393
+ regionStart = strandedHeaderStart(source, regionStart, headers) ?? regionStart;
395
394
  let regionEnd = lastImport.end;
396
395
  if (source[regionEnd] === "\n") regionEnd++;
397
396
  const before = source.slice(0, regionStart);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "apotheke",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "description": "Prettier for imports — deterministic import organization as a Prettier plugin or CLI",
5
5
  "type": "module",
6
6
  "license": "MIT",