Skip to content

Commit 95c7d3d

Browse files
author
YuvalFireFly
committed
Add comments
1 parent 29b2bcc commit 95c7d3d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/index.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ async function main() {
3333
await localFireflyClient.login();
3434
}
3535

36+
// MCP server should not write stdout logs as it listens to the stdout. Check if it is changed
3637
if (debug) {
3738
logger.setLevel(logger.levels.DEBUG, true);
3839
} else {
@@ -136,12 +137,14 @@ async function main() {
136137
};
137138
});
138139

140+
// Hosted server needs to reset every hour to prevent timeout requests and issues connecting to the server
139141
if (hosting) {
140142
const app = express();
141143

142144
app.get("/sse", async (req: express.Request, res: express.Response) => {
143145
logger.debug("Received connection");
144146

147+
// Authentication improved since then, this is not best practice
145148
let basicAuth = null;
146149
const authHeader = req.headers.authorization;
147150
if (authHeader && authHeader.startsWith("Basic ")) {

0 commit comments

Comments
 (0)