Skip to content

Commit 476ab7a

Browse files
authored
Merge pull request #112 from better-stack-ai/docs/update-media-plugin
docs: update media plugin doc
2 parents 335b880 + 2b37ddf commit 476ab7a

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

docs/content/docs/plugins/media.mdx

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ Import and register the media backend plugin in your `stack.ts` file:
3636

3737
```ts title="lib/stack.ts"
3838
import { stack } from "@btst/stack"
39-
import { mediaBackendPlugin, localAdapter } from "@btst/stack/plugins/media/api"
39+
import { mediaBackendPlugin } from "@btst/stack/plugins/media/api"
40+
import { localAdapter } from "@btst/stack/plugins/media/api/adapters/local"
4041

4142
const { handler, dbSchema } = stack({
4243
basePath: "/api/data",
@@ -395,7 +396,8 @@ Returning `null` or `undefined` from `resolveTenantId` disables scoping for that
395396

396397
```ts title="lib/stack.ts"
397398
import { stack } from "@btst/stack"
398-
import { mediaBackendPlugin, s3Adapter } from "@btst/stack/plugins/media/api"
399+
import { mediaBackendPlugin } from "@btst/stack/plugins/media/api"
400+
import { s3Adapter } from "@btst/stack/plugins/media/api/adapters/s3"
399401
import { getSession } from "@/lib/auth"
400402

401403
const { handler, dbSchema } = stack({
@@ -464,7 +466,8 @@ Customize backend behavior with optional lifecycle hooks for uploads, listing, f
464466
**Example usage:**
465467

466468
```ts
467-
import { mediaBackendPlugin, localAdapter } from "@btst/stack/plugins/media/api"
469+
import { mediaBackendPlugin } from "@btst/stack/plugins/media/api"
470+
import { localAdapter } from "@btst/stack/plugins/media/api/adapters/local"
468471

469472
mediaBackendPlugin({
470473
storageAdapter: localAdapter(),

0 commit comments

Comments
 (0)