summary refs log tree commit diff
path: root/src/api/middlewares
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2023-03-31 15:52:33 +1100
committerMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2023-03-31 15:52:33 +1100
commit095cbf7b2036bc35d9c3eabbdec8a5c6dfd67242 (patch)
tree72bc2d6b975855c020e5dd9612a5113b4bf7c2e3 /src/api/middlewares
parentRevert "Merge pull request #1008 from spacebarchat/dev/samuel" (diff)
downloadserver-095cbf7b2036bc35d9c3eabbdec8a5c6dfd67242.tar.xz
Remove ALL fosscord mentions
Diffstat (limited to 'src/api/middlewares')
-rw-r--r--src/api/middlewares/Authentication.ts2
-rw-r--r--src/api/middlewares/ErrorHandler.ts2
-rw-r--r--src/api/middlewares/RateLimit.ts6
3 files changed, 5 insertions, 5 deletions
diff --git a/src/api/middlewares/Authentication.ts b/src/api/middlewares/Authentication.ts
index 400a16f4..09644eee 100644
--- a/src/api/middlewares/Authentication.ts
+++ b/src/api/middlewares/Authentication.ts
@@ -16,7 +16,7 @@
 	along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */
 
-import { checkToken, Config, Rights } from "@fosscord/util";
+import { checkToken, Config, Rights } from "@spacebar/util";
 import * as Sentry from "@sentry/node";
 import { NextFunction, Request, Response } from "express";
 import { HTTPError } from "lambert-server";
diff --git a/src/api/middlewares/ErrorHandler.ts b/src/api/middlewares/ErrorHandler.ts
index 439fce68..b8a73298 100644
--- a/src/api/middlewares/ErrorHandler.ts
+++ b/src/api/middlewares/ErrorHandler.ts
@@ -18,7 +18,7 @@
 
 import { NextFunction, Request, Response } from "express";
 import { HTTPError } from "lambert-server";
-import { ApiError, FieldError } from "@fosscord/util";
+import { ApiError, FieldError } from "@spacebar/util";
 const EntityNotFoundErrorRegex = /"(\w+)"/;
 
 export function ErrorHandler(
diff --git a/src/api/middlewares/RateLimit.ts b/src/api/middlewares/RateLimit.ts
index f50d6568..0da292e9 100644
--- a/src/api/middlewares/RateLimit.ts
+++ b/src/api/middlewares/RateLimit.ts
@@ -16,8 +16,8 @@
 	along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */
 
-import { getIpAdress } from "@fosscord/api";
-import { Config, getRights, listenEvent } from "@fosscord/util";
+import { getIpAdress } from "@spacebar/api";
+import { Config, getRights, listenEvent } from "@spacebar/util";
 import { NextFunction, Request, Response, Router } from "express";
 import { API_PREFIX_TRAILING_SLASH } from "./Authentication";
 
@@ -27,7 +27,7 @@ import { API_PREFIX_TRAILING_SLASH } from "./Authentication";
 
 /*
 ? bucket limit? Max actions/sec per bucket?
-(ANSWER: a small fosscord instance might not need a complex rate limiting system)
+(ANSWER: a small spacebar instance might not need a complex rate limiting system)
 TODO: delay database requests to include multiple queries
 TODO: different for methods (GET/POST)
 > IP addresses that make too many invalid HTTP requests are automatically and temporarily restricted from accessing the Discord API. Currently, this limit is 10,000 per 10 minutes. An invalid request is one that results in 401, 403, or 429 statuses.