Skip to content

Commit d0359b1

Browse files
committed
chore: add TODOs
1 parent 6c13436 commit d0359b1

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

frontend/pb.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ export function PasteBin() {
120120

121121
// handle admin URL
122122
useEffect(() => {
123+
// TODO: do not fetch paste for a large file paste
123124
const pathname = location.pathname
124125
const { nameFromPath, passwd, filename, ext } = parsePath(pathname)
125126

@@ -201,6 +202,7 @@ export function PasteBin() {
201202
setIsLoading(true)
202203
setPasteResponse(null)
203204
const isUpdate = uploadKind !== "manage"
205+
// TODO: add progress indicator
204206
const resp = isUpdate
205207
? await fetch(APIUrl, {
206208
method: "POST",

src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ async function handleRequest(request: Request, env: Env, ctx: ExecutionContext):
4545
}
4646

4747
async function handleNormalRequest(request: Request, env: Env, ctx: ExecutionContext): Promise<Response> {
48+
// TODO: support HEAD method
4849
if (request.method === "POST") {
4950
return await handlePostOrPut(request, env, ctx, false)
5051
} else if (request.method === "GET") {

src/storage/storage.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ export async function getPaste(env: Env, short: string, ctx: ExecutionContext):
113113
if (object === null) {
114114
return null
115115
}
116+
// TODO: how Content-Length handled?
116117
return { paste: object.body, metadata }
117118
} else {
118119
return { paste: item.value, metadata }

0 commit comments

Comments
 (0)