Skip to content

New Update - #9

Open
celesteoffi wants to merge 56 commits into
gazes-media:mainfrom
celesteoffi:main
Open

New Update#9
celesteoffi wants to merge 56 commits into
gazes-media:mainfrom
celesteoffi:main

Conversation

@celesteoffi

Copy link
Copy Markdown

No description provided.

@gitguardian

gitguardian Bot commented Jul 22, 2025

Copy link
Copy Markdown

️✅ There are no secrets present in this pull request anymore.

If these secrets were true positive and are still valid, we highly recommend you to revoke them.
While these secrets were previously flagged, we no longer have a reference to the
specific commits where they were detected. Once a secret has been leaked into a git
repository, you should consider it compromised, even if it was deleted immediately.
Find here more information about risks.


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

@garder500
garder500 requested a review from Copilot July 22, 2025 13:39

This comment was marked as outdated.

@garder500
garder500 requested a review from Copilot July 22, 2025 13:42

Copilot AI left a comment

Copy link
Copy Markdown

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 implements a comprehensive rebranding from "Ketsuna" to "Morgane AI" along with significant feature additions including Discord bot sharding capabilities, blacklist functionality, and new slash commands. The changes modernize the codebase and add robust user management features.

  • Rebrands the entire application from "Ketsuna" to "Morgane AI" with updated URLs and references
  • Implements Discord bot sharding system with management commands and monitoring capabilities
  • Adds comprehensive blacklist functionality to restrict user access to commands
  • Introduces multiple new slash commands for bot interaction and information display

Reviewed Changes

Copilot reviewed 27 out of 30 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
whitelist.json New whitelist configuration file with initial user ID
src/utils/blacklist.ts Blacklist utility functions for user access control
src/shard.ts Complete sharding system implementation with management commands
src/main.ts Updated main entry point with shard support and removed website integration
src/bot/list.commands.ts Exports for new command modules
src/bot/index.ts Core bot rebranding and updated configuration
src/bot/commands/* Multiple new slash commands with blacklist integration
src/blacklist.ts Alternative blacklist implementation
package.json Added node-fetch dependency
blacklist.json Blacklist configuration with user IDs
README.md Complete documentation rewrite for Morgane AI
.swcrc Simplified build configuration
Comments suppressed due to low confidence (1)

src/bot/commands/vote.ts:17

  • The class name "GayCommand" does not match the command functionality which is for voting. It should be renamed to "VoteCommand" to reflect its actual purpose.
export class GayCommand extends CommandsBase {

Comment thread src/utils/blacklist.ts
// Fonction pour charger la liste noire à partir du fichier JSON
export function loadBlacklist(): string[] {
try {
const data = fs.readFileSync("../blacklist.json", "utf8");

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

The relative path "../blacklist.json" is unreliable and may not work correctly when the code is executed from different directories. Use path.resolve() with __dirname to create an absolute path.

Suggested change
const data = fs.readFileSync("../blacklist.json", "utf8");
const data = fs.readFileSync(path.resolve(__dirname, "../blacklist.json"), "utf8");

Copilot uses AI. Check for mistakes.
Comment thread src/utils/blacklist.ts
// Fonction pour sauvegarder la liste noire dans le fichier JSON
export function saveBlacklist(blacklist: string[]): void {
const jsonData = JSON.stringify({ blacklist }, null, 2);
fs.writeFileSync("../blacklist.json", jsonData, "utf8");

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

The relative path "../blacklist.json" is unreliable and may not work correctly when the code is executed from different directories. Use path.resolve() with __dirname to create an absolute path.

Copilot uses AI. Check for mistakes.
Comment thread src/utils/blacklist.ts
const json = JSON.parse(data);
return json.blacklist || [];
} catch (err) {
console.error("Erreur de chargement de la blacklist : ", err);

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] The error message is in French. For consistency with the codebase which appears to be primarily in English, consider using "Error loading blacklist:" instead of "Erreur de chargement de la blacklist :".

Suggested change
console.error("Erreur de chargement de la blacklist : ", err);
console.error("Error loading blacklist:", err);

Copilot uses AI. Check for mistakes.
Comment thread src/shard.ts

dotenv.config();

// Vérification des variables d'environnement

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] Comment is in French. For consistency with the codebase, consider using English: "// Environment variables verification".

Suggested change
// Vérification des variables d'environnement
// Environment variables verification

Copilot uses AI. Check for mistakes.
Comment thread src/bot/commands/vote.ts
Comment on lines +27 to +29
phrase: "https://top.gg/fr/bot/1190014646351036577",
locale: interaction.locale,
}, randomPercentage.toString()),

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

The vote command generates a random percentage but doesn't use it meaningfully. The variable is passed to a localization function that expects a URL, not a percentage, making this functionality broken.

Suggested change
phrase: "https://top.gg/fr/bot/1190014646351036577",
locale: interaction.locale,
}, randomPercentage.toString()),
phrase: `You voted with a confidence level of ${randomPercentage}%!`,
locale: interaction.locale,
}),

Copilot uses AI. Check for mistakes.
Comment thread src/shard.ts

if (GUILD_COUNT === 0) {
console.log("[ShardManager] The bot is not in any guilds. Exiting...");
process.exit(1); // Si le bot n'est dans aucune guilde, sortir

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] Comment is in French. For consistency, use English: "// If the bot is not in any guilds, exit".

Suggested change
process.exit(1); // Si le bot n'est dans aucune guilde, sortir
process.exit(1); // If the bot is not in any guilds, exit

Copilot uses AI. Check for mistakes.
Comment thread src/main.ts
import dotenv from "dotenv";
import Bot from "./bot";
import Website from "./website";
import Bot from "./bot"; // Assure-toi que la classe Bot est bien définie pour gérer ton bot

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] Comment is in French. For consistency, use English: "// Make sure the Bot class is properly defined to handle your bot".

Suggested change
import Bot from "./bot"; // Assure-toi que la classe Bot est bien définie pour gérer ton bot
import Bot from "./bot"; // Make sure the Bot class is properly defined to handle your bot

Copilot uses AI. Check for mistakes.
Comment thread src/bot/commands/ai/imagine.ts Outdated
return {
attachment: generation.img,
name: 'image' + i + '.webp'
name: 'image' + i + '.png'

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] Use template literals for better readability: image${i}.png instead of string concatenation.

Suggested change
name: 'image' + i + '.png'
name: `image${i}.png`

Copilot uses AI. Check for mistakes.
Comment thread src/blacklist.ts Outdated
const json = JSON.parse(data);
return json.blacklist || [];
} catch (err) {
console.error("Erreur de chargement de la blacklist : ", err);

Copilot AI Jul 22, 2025

Copy link

Choose a reason for hiding this comment

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

[nitpick] Error message is in French. For consistency, use English: "Error loading blacklist:".

Suggested change
console.error("Erreur de chargement de la blacklist : ", err);
console.error("Error loading blacklist:", err);

Copilot uses AI. Check for mistakes.
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.

2 participants