mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-11-06 21:02:28 +00:00
refactor(ai): extract handleAddProfile from js/app.js (agent)
Moves `handleAddProfile` logic from the main application class into `ProfileModalController` to improve separation of concerns as per `AGENTS.md`. - Extracts `handleAddProfile` to `js/ui/profileModalController.js`. - Updates `ProfileModalController` to handle add account flow internally. - Removes legacy callback wiring from `js/app.js` and `js/ui/applicationBootstrap.js`. - Adds unit tests for the extracted logic in `tests/ui/profileModalController-addProfile.test.mjs`. Co-authored-by: PR0M3TH3AN <[email protected]>
This commit is contained in:
1 parent
8c331f8c14
commit
51087fad7e
4 files changed
+320
-156
No files matched your search
@@ -571,7 +571,6 @@ export default class ApplicationBootstrap {
|
||||
onClose: () => app.handleProfileModalClosed(),
|
||||
onLogout: async () => app.requestLogout(),
|
||||
onChannelLink: (element) => app.handleProfileChannelLink(element),
|
||||
onAddAccount: (payload) => app.handleAddProfile(payload),
|
||||
onRequestLogoutProfile: (payload) =>
|
||||
app.handleProfileLogoutRequest(payload),
|
||||
onRequestSwitchProfile: (payload) =>
|
||||
|
||||
Reference in new issue
Block a user