Skip to content

Commit

Permalink
chore: some knip fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Keyrxng committed Sep 13, 2024
1 parent 11862fd commit d9cdd37
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 282 deletions.
11 changes: 1 addition & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,27 +40,20 @@
"@actions/github": "6.0.0",
"@grammyjs/auto-chat-action": "0.1.1",
"@grammyjs/hydrate": "1.4.1",
"@grammyjs/i18n": "1.0.2",
"@grammyjs/parse-mode": "1.10.0",
"@grammyjs/runner": "2.0.3",
"@grammyjs/types": "3.13.0",
"@octokit/rest": "21.0.2",
"@octokit/webhooks": "13.3.0",
"@sinclair/typebox": "0.33.7",
"@supabase/supabase-js": "^2.45.3",
"@ubiquity-dao/ubiquibot-logger": "^1.3.1",
"callback-data": "1.1.1",
"dotenv": "16.4.5",
"grammy": "^1.29.0",
"grammy-guard": "0.5.0",
"hono": "^4.5.9",
"iso-639-1": "3.1.2",
"octokit": "^4.0.2",
"pino": "9.3.2",
"pino-pretty": "11.2.2",
"telegram": "^2.24.11",
"typebox-validators": "0.3.5",
"valibot": "0.39.0"
"typebox-validators": "0.3.5"
},
"devDependencies": {
"@cloudflare/workers-types": "^4.20240529.0",
Expand All @@ -74,7 +67,6 @@
"@mswjs/data": "0.16.1",
"@types/jest": "^29.5.12",
"@types/node": "22.5.0",
"@types/tdweb": "^1.4.5",
"cspell": "8.14.2",
"eslint": "9.9.1",
"eslint-config-prettier": "9.1.0",
Expand All @@ -91,7 +83,6 @@
"lint-staged": "15.2.9",
"npm-run-all": "4.1.5",
"prettier": "3.3.3",
"smee-client": "^2.0.3",
"ts-jest": "29.2.5",
"tsc-watch": "^6.2.0",
"tsx": "4.18.0",
Expand Down
7 changes: 0 additions & 7 deletions src/adapters/supabase/helpers/chats.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
import { SupabaseClient } from "@supabase/supabase-js";
import { Super } from "./supabase";

export type Chat = {
chatId: number;
chatName: string;
taskNodeId: string;
status: string;
};

/**
* Handles all telegram chat storage and retrieval
*/
Expand Down
2 changes: 0 additions & 2 deletions src/server/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,3 @@ export function createServer(dependencies: Dependencies) {

return server;
}

export type Server = Awaited<ReturnType<typeof createServer>>;
9 changes: 0 additions & 9 deletions src/types/typeguards.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
import { GrammyTelegramUpdate } from "#root/bot/helpers/grammy-context.js";
import { Context } from "./context";
import { PluginInputs } from "./plugin-inputs";

export function isIssueOpenedEvent(context: Context): context is Context<"issues.opened"> {
return context.eventName === "issues.opened";
}

export function isTelegramPayload(payload: unknown): payload is GrammyTelegramUpdate {
if (typeof payload !== "object" || !payload) return false;
return "update_id" in payload && payload.update_id !== undefined;
Expand All @@ -15,7 +10,3 @@ export function isGithubPayload(inputs: unknown): inputs is PluginInputs {
if (typeof inputs !== "object" || !inputs) return false;
return "eventName" in inputs && inputs.eventName !== undefined;
}

export function isIssueLabeledEvent(context: Context): context is Context<"issues.labeled"> {
return context.eventName === "issues.labeled";
}
Loading

0 comments on commit d9cdd37

Please sign in to comment.