diff options
| author | Bobby <[email protected]> | 2026-01-20 14:19:25 +0530 |
|---|---|---|
| committer | Bobby <[email protected]> | 2026-01-20 14:19:25 +0530 |
| commit | a04faab2a7c031b95e6e7553f9921c3bada2bc08 (patch) | |
| tree | 91c77399eac06aeb7417ed367123321f223bcfd7 /processors/metadata.go | |
| parent | 97459ee6173299aa352ac29b2a77dd8df7e3ab3d (diff) | |
| download | cafe-a04faab2a7c031b95e6e7553f9921c3bada2bc08.tar.xz cafe-a04faab2a7c031b95e6e7553f9921c3bada2bc08.zip | |
Implemented processors and add HTTPRequest and HTTPQueryParam types and Created utility functions for building request metadata.
Diffstat (limited to 'processors/metadata.go')
| -rw-r--r-- | processors/metadata.go | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/processors/metadata.go b/processors/metadata.go new file mode 100644 index 0000000..9f2fbfb --- /dev/null +++ b/processors/metadata.go @@ -0,0 +1,17 @@ +package processors + +import ( + "cafe/config" + + "github.com/gofiber/fiber/v2" +) + +const defaultTitle = "Shifoo's Cafe" + +func metadata(ctx *fiber.Ctx) error { + ctx.Locals("Title", defaultTitle) + ctx.Locals("AppName", config.Server.AppName) + ctx.Locals("AppDescription", config.Server.AppDescription) + + return ctx.Next() +} |
