Skip to content
This repository has been archived by the owner on Nov 18, 2024. It is now read-only.

Commit

Permalink
Prettier fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Froxcey committed Jan 30, 2024
1 parent 9ab990b commit dff5bc4
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 18 deletions.
2 changes: 1 addition & 1 deletion src/adapters/discord.js/toPlatform.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { MessageContent } from "../";
import { MessageContent } from "../";

export function messageRebuild(content: MessageContent) {
if (typeof content == "string") return content;
Expand Down
2 changes: 1 addition & 1 deletion src/adapters/guilded.js/toCommon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { messageRebuild } from "./toPlatform";
export function adaptMessage(message: GuildedMessage, client: Client): Message {
return {
type: "Message",
platform: {name: "guilded", host: "guilded.gg"},
platform: { name: "guilded", host: "guilded.gg" },
content: message.content as string,
author: {
name: message.author?.name ?? null,
Expand Down
8 changes: 4 additions & 4 deletions src/froxKit/combinedEvent.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { Emitter, EventMap } from "strict-event-emitter";

export class CombinedEmitter<T extends EventMap> extends Emitter<T> {
private eventList: Array<keyof T>
constructor(eventList: Array<keyof T>){
super()
this.eventList = eventList
private eventList: Array<keyof T>;
constructor(eventList: Array<keyof T>) {
super();
this.eventList = eventList;
}
addEmitters(emitters: Emitter<T>[]) {
for (let emitter of emitters) {
Expand Down
2 changes: 1 addition & 1 deletion src/froxKit/types.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Strips all undefined field from a type.
* Strips all undefined field from a type.
*/
export type DeepStripOptional<T> = {
[K in keyof T]-?: T[K] extends object ? DeepStripOptional<T[K]> : T[K];
Expand Down
4 changes: 1 addition & 3 deletions src/panel/apiRoute.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
export function handler (req: Request) {

}
export function handler(req: Request) {}
10 changes: 3 additions & 7 deletions src/panel/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Result } from "ts-results";
import {SocketRunner} from "../websocket";
import { SocketRunner } from "../websocket";

export interface PanelConfig {
port?: number;
Expand All @@ -20,15 +20,11 @@ export class PanelRunner {
const url = new URL(req.url);

if (url.pathname.startsWith("/lib")) {
return new Response(
Bun.file("src/panel" + url.pathname),
);
return new Response(Bun.file("src/panel" + url.pathname));
}

if (url.pathname.startsWith("/api")) {
return new Response(

)
return new Response();
}

switch (url.pathname) {
Expand Down
2 changes: 1 addition & 1 deletion test/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ if (RUN.indexOf("GUILDED") != -1 && process.env.GUILDED_TOKEN) {
}

// This is on the host side
const PORT = 4289
const PORT = 4289;
let app = new MtcHost();
app.registerPlatforms(platforms);
app.socket.start(PORT).validator = (extInfo) =>
Expand Down

0 comments on commit dff5bc4

Please sign in to comment.