catto.js 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/MessageBuilder.js +3 -1
- package/Server.js +3 -3
- package/package.json +1 -1
package/MessageBuilder.js
CHANGED
|
@@ -23,7 +23,9 @@ class MessageBuilder {
|
|
|
23
23
|
if (!basic.id && !basic.url) {
|
|
24
24
|
throw new Error("All buttons except URL must have ID.");
|
|
25
25
|
}
|
|
26
|
-
|
|
26
|
+
if (basic.id) {
|
|
27
|
+
btn.setCustomId(basic.id);
|
|
28
|
+
}
|
|
27
29
|
if (basic.disabled) {
|
|
28
30
|
btn.setDisabled(!0);
|
|
29
31
|
} else {
|
package/Server.js
CHANGED
|
@@ -129,9 +129,9 @@ class Server extends EventEmitter {
|
|
|
129
129
|
this.app.ws(...args);
|
|
130
130
|
return this;
|
|
131
131
|
}
|
|
132
|
-
static(folder,
|
|
133
|
-
if (
|
|
134
|
-
this.app.use(
|
|
132
|
+
static(folder, pathname) {
|
|
133
|
+
if (pathname) {
|
|
134
|
+
this.app.use(pathname, express.static(path.join(__dirname,"..","..",folder)));
|
|
135
135
|
} else {
|
|
136
136
|
this.app.use(express.static(path.join(__dirname,"..","..",folder)));
|
|
137
137
|
}
|