diff options
author | Elizabeth Hunt <me@liz.coffee> | 2025-07-27 18:50:33 -0700 |
---|---|---|
committer | Elizabeth Hunt <me@liz.coffee> | 2025-07-27 19:31:06 -0700 |
commit | 7aa11b7a8abacf81dec20fff21216df35d333756 (patch) | |
tree | 40f6a76c37412cf1c5a67f99a4ee30e3aae863c9 /u/server/activity/fourohfour.ts | |
parent | e4df72cd446270cf867ec308995a05e21b3aa601 (diff) | |
download | ci-7aa11b7a8abacf81dec20fff21216df35d333756.tar.gz ci-7aa11b7a8abacf81dec20fff21216df35d333756.zip |
Pulls in pengueno from npm
Diffstat (limited to 'u/server/activity/fourohfour.ts')
-rw-r--r-- | u/server/activity/fourohfour.ts | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/u/server/activity/fourohfour.ts b/u/server/activity/fourohfour.ts deleted file mode 100644 index cd90ba0..0000000 --- a/u/server/activity/fourohfour.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { - type IActivity, - type ITraceable, - JsonResponse, - type PenguenoRequest, - type ServerTrace, -} from '@emprespresso/pengueno'; - -const messages = [ - 'D: meow-t found! your api call ran away!', - '404-bidden! but like...in a cute way >:3 !', - ':< your data went on a paw-sible vacation!', - 'uwu~ not found, but found our hearts instead!', -]; -const randomFourOhFour = () => messages[Math.floor(Math.random() * messages.length)]!; - -export interface IFourOhFourActivity { - fourOhFour: IActivity; -} - -export class FourOhFourActivityImpl implements IFourOhFourActivity { - public fourOhFour(req: ITraceable<PenguenoRequest, ServerTrace>) { - return req - .move(new JsonResponse(req, randomFourOhFour(), { status: 404 })) - .map((resp) => Promise.resolve(resp.get())) - .get(); - } -} |