Skip to content

chore: Remove duplicate and obsolete legacy code#2050

Merged
LouisCAD merged 1 commit into
mainfrom
remove-legacy-code
Jul 6, 2026
Merged

chore: Remove duplicate and obsolete legacy code#2050
LouisCAD merged 1 commit into
mainfrom
remove-legacy-code

Conversation

@LouisCAD

@LouisCAD LouisCAD commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Copilot AI review requested due to automatic review settings July 6, 2026 13:14
@github-actions github-actions Bot added the dependent This MR depends on another PR label Jul 6, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR continues the de-legacy effort by switching several app call sites from core.legacy.* utilities/APIs to the newer Core modules (network + Coil3), and removing duplicate legacy implementations.

Changes:

  • Replace legacy UI/avatar helpers and legacy networking imports with com.infomaniak.core.coil.* and com.infomaniak.core.network.*.
  • Migrate multiple adapters/dialog image-loading call sites from Coil 2 (coil.*) to Coil 3 (coil3.*).
  • Remove the duplicate legacy public-share token interceptor and tighten a Dropbox-related API return type.

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
app/src/main/java/com/infomaniak/drive/ui/MainActivity.kt Switch avatar helpers from legacy UtilsUi to new Core Coil helpers.
app/src/main/java/com/infomaniak/drive/ui/home/LastActivitiesAdapter.kt Migrate coil.load usage to coil3.load.
app/src/main/java/com/infomaniak/drive/ui/fileList/preview/PreviewVideoFragment.kt Switch from legacy networking (core.legacy.networking) to new Core network APIs.
app/src/main/java/com/infomaniak/drive/ui/fileList/fileShare/SharedItemsAdapter.kt Migrate coil.load usage to coil3.load.
app/src/main/java/com/infomaniak/drive/ui/fileList/fileShare/FileShareAddUserDialog.kt Migrate Coil request/execution code to Coil 3 and replace legacy Coil helpers with Core Coil helpers.
app/src/main/java/com/infomaniak/drive/ui/fileList/fileShare/AvailableShareableItemsAdapter.kt Migrate coil.load usage to coil3.load.
app/src/main/java/com/infomaniak/drive/ui/fileList/fileDetails/FileActivitiesAdapter.kt Migrate coil.load usage to coil3.load.
app/src/main/java/com/infomaniak/drive/ui/dropbox/DropboxViewModel.kt Make the LiveData return type explicit using the new ApiResponse model.
app/src/main/java/com/infomaniak/drive/MainApplication.kt Remove legacy core init/debug tooling and initialize new Core modules (but currently hard-codes PreProd env).
app/src/main/java/com/infomaniak/drive/data/api/publicshare/PublicShareTokenInterceptor.kt Remove duplicate legacy public-share interceptor implementation and legacy aliases.
app/src/androidTest/java/com/infomaniak/drive/KDriveTest.kt Update test networking imports and OkHttp client source to new Core network client.

Comment thread app/src/main/java/com/infomaniak/drive/MainApplication.kt
@LouisCAD LouisCAD force-pushed the remove-legacy-code branch from e4487c1 to 804d7dc Compare July 6, 2026 13:36
@github-actions github-actions Bot removed the dependent This MR depends on another PR label Jul 6, 2026
@github-actions

github-actions Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

This PR/issue depends on:

@LouisCAD LouisCAD force-pushed the remove-legacy-code branch from 804d7dc to 7acd3ab Compare July 6, 2026 13:44
@LouisCAD LouisCAD enabled auto-merge July 6, 2026 13:46
@LouisCAD LouisCAD force-pushed the remove-legacy-code branch from 7acd3ab to 9b0b947 Compare July 6, 2026 15:21
@sonarqubecloud

sonarqubecloud Bot commented Jul 6, 2026

Copy link
Copy Markdown

@LouisCAD LouisCAD merged commit efc4a08 into main Jul 6, 2026
9 checks passed
@LouisCAD LouisCAD deleted the remove-legacy-code branch July 6, 2026 15:26
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.

3 participants