aboutsummaryrefslogtreecommitdiff
path: root/packages/server/src/git/blob.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/server/src/git/blob.ts')
-rw-r--r--packages/server/src/git/blob.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/server/src/git/blob.ts b/packages/server/src/git/blob.ts
index 5d1d892..ad88ca5 100644
--- a/packages/server/src/git/blob.ts
+++ b/packages/server/src/git/blob.ts
@@ -1,4 +1,4 @@
-import { BlobError, createError } from "./error";
+import { createError, ErrorWhere, IsNotError } from "./error";
import { Tree } from "./tree";
import { BlobTreeEntry } from "./tree_entry";
@@ -37,7 +37,7 @@ export class Blob {
const entry = await tree.find(path);
if(!(entry instanceof BlobTreeEntry)) {
- throw(createError(BlobError, 500, "Not a blob"));
+ throw(createError(ErrorWhere.Blob, IsNotError, "tree entry", "a blob"));
}
return new Blob(entry);