Skip to content

Commit

Permalink
fix: Set default port to 8030
Browse files Browse the repository at this point in the history
  • Loading branch information
Snazzah committed Dec 17, 2020
1 parent fd9c50c commit ab06e21
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion lib/creator.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class SlashCreator extends eventemitter3_1.default {
requestTimeout: 15000,
maxSignatureTimestamp: 5000,
endpointPath: '/interactions',
serverPort: 80,
serverPort: 8030,
serverHost: 'localhost'
}, opts);
this.allowedMentions = util_1.formatAllowedMentions(this.options.allowedMentions);
Expand Down
4 changes: 2 additions & 2 deletions lib/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ class Server {
throw new Error(`${this.constructor.name} doesn't have a handleInteraction method.`);
}
/** @private */
async listen(port = 80, host = 'localhost') {
throw new Error(`${this.constructor.name} doesn't have a listen method.`);
async listen(port = 8030, host = 'localhost') {
throw new Error(`${this.constructor.name} doesn't have a listen method. You should remove \`.startServer()\`.`);
}
}
exports.default = Server;
2 changes: 1 addition & 1 deletion lib/servers/express.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class ExpressServer extends server_1.default {
}));
}
/** @private */
async listen(port = 80, host = 'localhost') {
async listen(port = 8030, host = 'localhost') {
if (this.alreadyListening)
return;
this.app.listen(port, host);
Expand Down
2 changes: 1 addition & 1 deletion lib/servers/fastify.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class FastifyServer extends server_1.default {
}));
}
/** @private */
async listen(port = 80, host = 'localhost') {
async listen(port = 8030, host = 'localhost') {
if (this.alreadyListening)
return;
await this.app.listen(port, host);
Expand Down
2 changes: 1 addition & 1 deletion src/creator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ class SlashCreator extends ((EventEmitter as any) as new () => TypedEmitter<Slas
requestTimeout: 15000,
maxSignatureTimestamp: 5000,
endpointPath: '/interactions',
serverPort: 80,
serverPort: 8030,
serverHost: 'localhost'
},
opts
Expand Down
4 changes: 2 additions & 2 deletions src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ class Server {
}

/** @private */
async listen(port = 80, host = 'localhost') {
throw new Error(`${this.constructor.name} doesn't have a listen method.`);
async listen(port = 8030, host = 'localhost') {
throw new Error(`${this.constructor.name} doesn't have a listen method. You should remove \`.startServer()\`.`);
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/servers/express.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class ExpressServer extends Server {
}

/** @private */
async listen(port = 80, host = 'localhost') {
async listen(port = 8030, host = 'localhost') {
if (this.alreadyListening) return;
this.app.listen(port, host);
}
Expand Down
2 changes: 1 addition & 1 deletion src/servers/fastify.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class FastifyServer extends Server {
}

/** @private */
async listen(port = 80, host = 'localhost') {
async listen(port = 8030, host = 'localhost') {
if (this.alreadyListening) return;
await this.app.listen(port, host);
}
Expand Down

0 comments on commit ab06e21

Please sign in to comment.