Skip to content

fix: mount point drag-and-drop reorder not persisted on save#1056

Merged
trim21 merged 3 commits intomasterfrom
copilot/fix-mountpath-order-change
Apr 5, 2026
Merged

fix: mount point drag-and-drop reorder not persisted on save#1056
trim21 merged 3 commits intomasterfrom
copilot/fix-mountpath-order-change

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 8, 2026

Reordering mount points via drag-and-drop and saving had no effect — the order reset on refresh. Toggling visibility worked fine because the checkbox handler called onSettingsChange; the onDrop handler did not.

Change

  • MountPointsList.tsxonDrop now calls onSettingsChange with the reordered visible mount points, matching the pattern already used in the checkbox handler and in TorrentListColumnsList:
// Before
onDrop={(items) => {
  setDiskItems(items.map((id) => ({id, visible: diskItemVisiblity[id]})));
}}

// After
onDrop={(items) => {
  const newItems = items.map((id) => ({id, visible: diskItemVisiblity[id]}));
  onSettingsChange({
    mountPoints: newItems.filter((newItem) => newItem.visible).map((newItem) => newItem.id),
  });
  setDiskItems(newItems);
}}
Original prompt

This section details on the original issue you should resolve

<issue_title>mountpath order only change not saved</issue_title>
<issue_description>Type: Bug Report

  • Try to follow the update procedure described in the README and try again before opening this issue.

Your Environment

  • Version used:
    • Version: master branch
    • Commit ID (development release) 2b652f8
  • Environment name and version:
    • Node.js version: 18.17.0
    • npm version: 9.8.1
    • Web browser: Chrome/116.0.0.0
  • Operating system and version: debian10
  • Torrent client and version: rtorrent jesec version

Summary

mountpath config page support drag and drop for sorting, but click save doesn't working.

Expected Behavior

Current Behavior

image

click save, refresh, then the order get reset

image

Possible Solution

Steps to Reproduce

  1. change mountpath order
  2. save config
  3. refresh
  4. find mount path order not saved

Context

if any selected mountPaths changed, the order will be updated as expected.

</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

…d-drop

Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix mountpath order change not saved issue fix: mount point drag-and-drop reorder not persisted on save Mar 8, 2026
@trim21 trim21 marked this pull request as ready for review April 5, 2026 11:48
@trim21 trim21 enabled auto-merge (squash) April 5, 2026 11:52
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 5, 2026

Codecov Report

❌ Patch coverage is 0% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 22.20%. Comparing base (7322d4a) to head (d1ceca5).
⚠️ Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
...ts/modals/settings-modal/lists/MountPointsList.tsx 0.00% 5 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1056   +/-   ##
=======================================
  Coverage   22.19%   22.20%           
=======================================
  Files         412      412           
  Lines       27571    27575    +4     
  Branches     1282     1280    -2     
=======================================
+ Hits         6119     6122    +3     
- Misses      21154    21155    +1     
  Partials      298      298           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@trim21 trim21 merged commit bea7783 into master Apr 5, 2026
24 of 25 checks passed
@trim21 trim21 deleted the copilot/fix-mountpath-order-change branch April 5, 2026 11:55
marcinmajsc added a commit to marcinmajsc/flood that referenced this pull request Apr 8, 2026
* feat: bind to `::` for dual-stack IPv4+IPv6 support in Docker (jesec#1063)

* Initial plan

* feat: support IPv6 in Docker containers by changing default host to ::

Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>

* fix(qbittorrent): show seeding ETA instead of ∞ (jesec#1060)

* chore(geoip): update GeoLite2-Country.mmdb (jesec#1058)

Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>
Co-authored-by: Trim21 <trim21.me@gmail.com>

* chore: update cron schedule for update-mmdb workflow (jesec#1066)

* build(deps-dev): bump fastify from 5.7.3 to 5.8.3 (jesec#1068)

Bumps [fastify](https://github.com/fastify/fastify) from 5.7.3 to 5.8.3.
- [Release notes](https://github.com/fastify/fastify/releases)
- [Commits](fastify/fastify@v5.7.3...v5.8.3)

---
updated-dependencies:
- dependency-name: fastify
  dependency-version: 5.8.3
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* fix: query string token authentication for torrent content downloads (jesec#1070)

* release: 4.13.1 (jesec#1071)

* build(deps-dev): bump lodash from 4.17.23 to 4.18.1 (jesec#1072)

Bumps [lodash](https://github.com/lodash/lodash) from 4.17.23 to 4.18.1.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](lodash/lodash@4.17.23...4.18.1)

---
updated-dependencies:
- dependency-name: lodash
  dependency-version: 4.18.1
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* i18n: new translations (jesec#1057)

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>

* chore(geoip): update GeoLite2-Country.mmdb (jesec#1067)

Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>

* fix: add `--no-git-checks` to pnpm publish for tag-based releases (jesec#1073)

* fix: mount point drag-and-drop reorder not persisted on save (jesec#1056)

* release: 4.13.2 (jesec#1074)

* fix: remove prepare script before packing npm tarball (jesec#1075)

The prepare script runs husky which is not available in CI publish
environment. Use jq to strip it from package.json before pnpm pack.

* release: 4.13.3 (jesec#1076)

* fix: remove unnecessary checkout in npm-publish job (jesec#1077)

The checkout causes 'No bin file found at dist/index.js' warning
because npm reads the local package.json which references dist/
that only exists inside the tarball. Publishing a tarball does not
require a repo checkout.

* release: 4.13.4 (jesec#1078)

* fix: specify pnpm version in npm-publish job (jesec#1079)

After removing checkout in jesec#1077, pnpm/action-setup can no longer
read packageManager from package.json. Explicitly specify version.

* release: 4.13.5 (jesec#1080)

* fix: use npm 11 for trusted publishing in npm-publish job (jesec#1081)

Trusted publishing requires npm CLI >= 11.5.1 for OIDC support.
pnpm does not support trusted publishing OIDC flow, and the empty
NODE_AUTH_TOKEN caused ENEEDAUTH instead of falling through to OIDC.

Switch to npm publish directly and install npm 11 globally.

* release: 4.13.6 (jesec#1082)

* fix: use manual OIDC token exchange for npm trusted publishing (jesec#1084)

* release: 4.13.7 (jesec#1085)

* fix: use proper MIME types for torrent content download (jesec#1086)

Replace manual file extension switch with mime-types library lookup
to return correct Content-Type headers (e.g. 'video/mp4' instead of
'.mp4'). Falls back to 'application/octet-stream' for unknown types.

* fix: prevent SKIPPED summary jobs from bypassing required checks (jesec#1088)

* fix: download torrent files with proper HTTP Range support using `@fastify/send` (jesec#1089)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: trim21 <13553903+trim21@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Trim21 <trim21.me@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: Kasra Fakhari <kasraf1373@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

mountpath order only change not saved

2 participants