Commit Graph
5 Commits
Author SHA1 Message Date
NoLogicAlan 6fa8f3b540 lots of changes 2026-05-16 20:30:56 +03:00
NoLogicAlan 5f33ee231d ok that alot 2026-05-11 22:24:08 +03:00
NoLogicAlan 991045f4dd fix: resolve startup crashes from missing exports, unsafe JSON parsing, and broken migrate/dashboard logic
Full rework and bugfix pass across the fluxer codebase to resolve
multiple runtime crashes that prevented the bot from starting and
loading guild settings correctly.

Export/Import Fixes:
- Added re-export of SettingsManager from settings/Settings.mjs
  into src/Settings.mjs to resolve missing named export error
  that crashed the bot on startup (affected CommandHandler,
  PlayerManager, and migrate.mjs)
- Verified all 70+ import/export chains across the entire project

JSON.parse Safety (mysql2 JSON column handling):
- src/Settings.mjs — added typeof guard before JSON.parse on
  RemoteSettingsManager.load() since mysql2 returns JSON columns
  as already-parsed objects, causing "[object Object]" SyntaxError
- settings/Settings.mjs — same typeof guard applied
- src/GatewayHandler.mjs — same typeof guard applied

Migrate Script Fix:
- settings/migrate.mjs — replaced abstract SettingsManager usage
  with concrete RemoteSettingsManager (which actually has the
  `guilds` property required for migration logic)

Dashboard Fix:
- src/dashboard/Dashboard.mjs — added missing reply() method to
  fakeMsg object so PlayerManager.initPlayer() doesn't crash when
  a user joins voice through the web dashboard

Files changed (13):
- src/Settings.mjs
- settings/Settings.mjs
- src/GatewayHandler.mjs
- settings/migrate.mjs
- src/dashboard/Dashboard.mjs
- src/CommandHandler.mjs
- src/PlayerManager.mjs
- src/MoonlinkManager.mjs
- src/Player.mjs
- src/RecoveryManager.mjs
- src/constants/audio/StreamMerger.mjs
- src/constants/audio/Tuna.mjs
- commands/remove.mjs
2026-05-06 23:33:57 +03:00
NoLogicAlan 85f11fe34b fix: migrate all commands & src to @fluxerjs native API
- Replace replyEmbed/sendEmbed/editEmbed with reply/send/edit
  across all 33 command files and 5 src/ files
- Remove unnecessary .toJSON() on EmbedBuilder (Fluxer auto-converts)
- Fix voice channel type checks: channel_type === "VoiceChannel" → type === 2
- Add missing edit() and send() methods to Message/ChannelContext wrappers
- Fix filter command: reactions now update per page on navigation

Closes channel cache crash (guild.channels.cache.keys undefined)
2026-05-05 20:09:25 +03:00
NoLogicAlan 2820cc881c initial push to remix-bot/fluxer 2026-04-14 02:23:18 +03:00