Skip to content

Commit

Permalink
fix: updated fetch-name to more reasonable
Browse files Browse the repository at this point in the history
  • Loading branch information
malmen237 committed Aug 30, 2024
1 parent b14a6f7 commit 7224680
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/api/manager/inventory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export async function getAudioMapping(id: ObjectId): Promise<IResponse> {
})) as IResponse;
}

export async function putDeleteFlagOnInventorySourceItem(
export async function purgeInventorySourceItem(
id: string
): Promise<UpdateResult<Document>> {
const db = await getDatabase();
Expand Down
4 changes: 2 additions & 2 deletions src/app/api/manager/inventory/[_id]/route.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { NextRequest, NextResponse } from 'next/server';
import { isAuthenticated } from '../../../../../api/manager/auth';
import { Params } from 'next/dist/shared/lib/router/utils/route-matcher';
import { putDeleteFlagOnInventorySourceItem } from '../../../../../api/manager/inventory';
import { purgeInventorySourceItem } from '../../../../../api/manager/inventory';

export async function PUT(
request: NextRequest,
Expand All @@ -14,7 +14,7 @@ export async function PUT(
}

try {
const response = await putDeleteFlagOnInventorySourceItem(params._id);
const response = await purgeInventorySourceItem(params._id);
if (response.acknowledged && response.modifiedCount === 0) {
return new NextResponse(`Did not match requirements`, {
status: 204
Expand Down

0 comments on commit 7224680

Please sign in to comment.