Skip to content

Commit

Permalink
lint lol
Browse files Browse the repository at this point in the history
  • Loading branch information
jackyzha0 committed Aug 12, 2024
1 parent d9d607f commit c5357f6
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions util/testHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
ServiceContextWithTransportInfo,
UNCAUGHT_ERROR,
} from '../router';
import { RiverError, Result, RiverUncaughtSchema } from '../router/result';
import { RiverError } from '../router/result';
import { Static } from '@sinclair/typebox';
import {
OpaqueTransportMessage,
Expand Down Expand Up @@ -260,19 +260,22 @@ export function asClientUpload<
session: Session<Connection> = dummySession(),
) {
const input = pushable<Static<I>>({ objectMode: true });
let result: Promise<ProcedureResult<O, E>>;
if (init) {
const _proc = proc as Procedure<State, 'upload', I, O, E, PayloadType>;
result = _proc
.handler(dummyCtx(state, session, extendedContext), init, input)
.catch(catchProcError);
return [input, result] as const;
return [
input,
_proc
.handler(dummyCtx(state, session, extendedContext), init, input)
.catch(catchProcError),
] as const;
} else {
const _proc = proc as Procedure<State, 'upload', I, O, E>;
result = _proc
.handler(dummyCtx(state, session, extendedContext), input)
.catch(catchProcError);
return [input, result] as const;
return [
input,
_proc
.handler(dummyCtx(state, session, extendedContext), input)
.catch(catchProcError),
] as const;
}
}

Expand Down

0 comments on commit c5357f6

Please sign in to comment.