MCPcopy Create free account
hub / github.com/SwishHQ/spread / ReportStatusDeploy

Method ReportStatusDeploy

src/controller/client_controller.go:49–62  ·  view source on GitHub ↗
(ctx *fiber.Ctx)

Source from the content-addressed store, hash-verified

47}
48
49func (c *clientController) ReportStatusDeploy(ctx *fiber.Ctx) error {
50 reportStatusRequest := new(types.ReportStatusDeployRequest)
51 validationErrors := utils.BindAndValidate(ctx, reportStatusRequest)
52 if len(validationErrors) > 0 {
53 logger.L.Error("In ReportStatusDeploy: Validation errors", zap.Any("validationErrors", validationErrors))
54 return ctx.Status(fiber.StatusOK).Send([]byte("OK"))
55 }
56 logger.L.Info("In ReportStatusDeploy", zap.Any("reportStatusRequest", reportStatusRequest))
57 err := c.clientService.ReportStatusDeploy(reportStatusRequest)
58 if err != nil {
59 logger.L.Error("In ReportStatusDeploy: Error reporting status", zap.Error(err))
60 }
61 return ctx.Status(fiber.StatusOK).Send([]byte("OK"))
62}
63
64func (c *clientController) ReportStatusDownload(ctx *fiber.Ctx) error {
65 reportStatusRequest := new(types.ReportStatusDownloadRequest)

Callers

nothing calls this directly

Calls 2

BindAndValidateFunction · 0.92
ReportStatusDeployMethod · 0.65

Tested by

no test coverage detected