anipalur / anipalur/gce-a-levels-bot

Use strings instead of IDs for `getLogsThread()`

Abierto
#13 0 comentarios 0 reacciones 0 asignados Ver en GitHub
enhancement good first issue
Lenguaje dominante
JavaScript
Estrellas
1
Forks
1
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

### Discord Username

Not specified.

### Related Problem

As of now, [`botLogsChannelId`](https://github.com/anipalur/gce-a-levels-bot/blob/79c543970c4fd6cbaa94b9683e944362fa0154a8/src/config/channels-example.json#L3 "View where botLogsChannelId is defined.") and a logs thread ID must be passed when calling [`getLogsThread()`](https://github.com/anipalur/gce-a-levels-bot/blob/79c543970c4fd6cbaa94b9683e944362fa0154a8/src/tools/get-logs-thread.js#L12 "View the getLogsThread function file."). These IDs must be imported in every file the function is used in.

### Enhancement Description

Use a string parameter to specify the logs thread. This string is used to reference the corresponding logs thread ID.

For example, instead of

```js
const serverLogsThread = getLogsThread(client, botLogsChannelId, serverLogsThreadId);
```

call `getLogsThread()` like this:

```js
const serverLogsThread = getLogsThread(client, 'server-logs');
```

### Additional Information

None.

### Code of Conduct

- [X] I agree to abide by the Code of Conduct.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.