Run go fix and go fmt
Signed-off-by: Sacha Al Himdani <sacha@getprobo.com>
This commit is contained in:
@@ -21,6 +21,6 @@ import (
|
||||
|
||||
type Factory struct {
|
||||
IOStreams *iostreams.IOStreams
|
||||
Version string
|
||||
Config func() (*config.Config, error)
|
||||
Version string
|
||||
Config func() (*config.Config, error)
|
||||
}
|
||||
|
||||
@@ -71,10 +71,10 @@ type viewResponse struct {
|
||||
ID string `json:"id"`
|
||||
FullName string `json:"fullName"`
|
||||
} `json:"owner"`
|
||||
DueDate *string `json:"dueDate"`
|
||||
Status string `json:"status"`
|
||||
Priority string `json:"priority"`
|
||||
Risk *struct {
|
||||
DueDate *string `json:"dueDate"`
|
||||
Status string `json:"status"`
|
||||
Priority string `json:"priority"`
|
||||
Risk *struct {
|
||||
ID string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
} `json:"risk"`
|
||||
|
||||
@@ -114,7 +114,6 @@ WHERE
|
||||
return err
|
||||
}
|
||||
|
||||
|
||||
func (cp ControlDocument) DeleteByDocumentIDs(
|
||||
ctx context.Context,
|
||||
conn pg.Conn,
|
||||
|
||||
@@ -37,7 +37,7 @@ type (
|
||||
ReferenceID string `db:"reference_id"`
|
||||
Description *string `db:"description"`
|
||||
Source *string `db:"source"`
|
||||
IdentifiedOn *time.Time `db:"identified_on"`
|
||||
IdentifiedOn *time.Time `db:"identified_on"`
|
||||
RootCause *string `db:"root_cause"`
|
||||
CorrectiveAction *string `db:"corrective_action"`
|
||||
OwnerID *gid.GID `db:"owner_id"`
|
||||
@@ -369,7 +369,7 @@ WHERE
|
||||
"identified_on": f.IdentifiedOn,
|
||||
"root_cause": f.RootCause,
|
||||
"corrective_action": f.CorrectiveAction,
|
||||
"owner_id": f.OwnerID,
|
||||
"owner_id": f.OwnerID,
|
||||
"due_date": f.DueDate,
|
||||
"status": f.Status,
|
||||
"priority": f.Priority,
|
||||
|
||||
@@ -47,16 +47,16 @@ func NewFindingFilter(
|
||||
|
||||
func (f *FindingFilter) SQLArguments() pgx.StrictNamedArgs {
|
||||
args := pgx.StrictNamedArgs{
|
||||
"has_snapshot_filter": false,
|
||||
"filter_snapshot_id": nil,
|
||||
"has_kind_filter": false,
|
||||
"filter_kind": nil,
|
||||
"has_status_filter": false,
|
||||
"filter_status": nil,
|
||||
"has_priority_filter": false,
|
||||
"filter_priority": nil,
|
||||
"has_owner_filter": false,
|
||||
"filter_owner_id": nil,
|
||||
"has_snapshot_filter": false,
|
||||
"filter_snapshot_id": nil,
|
||||
"has_kind_filter": false,
|
||||
"filter_kind": nil,
|
||||
"has_status_filter": false,
|
||||
"filter_status": nil,
|
||||
"has_priority_filter": false,
|
||||
"filter_priority": nil,
|
||||
"has_owner_filter": false,
|
||||
"filter_owner_id": nil,
|
||||
}
|
||||
|
||||
if f.snapshotID != nil {
|
||||
|
||||
@@ -21,13 +21,13 @@ import (
|
||||
type FindingOrderField string
|
||||
|
||||
const (
|
||||
FindingOrderFieldCreatedAt FindingOrderField = "CREATED_AT"
|
||||
FindingOrderFieldCreatedAt FindingOrderField = "CREATED_AT"
|
||||
FindingOrderFieldIdentifiedOn FindingOrderField = "IDENTIFIED_ON"
|
||||
FindingOrderFieldDueDate FindingOrderField = "DUE_DATE"
|
||||
FindingOrderFieldStatus FindingOrderField = "STATUS"
|
||||
FindingOrderFieldPriority FindingOrderField = "PRIORITY"
|
||||
FindingOrderFieldReferenceId FindingOrderField = "REFERENCE_ID"
|
||||
FindingOrderFieldKind FindingOrderField = "KIND"
|
||||
FindingOrderFieldDueDate FindingOrderField = "DUE_DATE"
|
||||
FindingOrderFieldStatus FindingOrderField = "STATUS"
|
||||
FindingOrderFieldPriority FindingOrderField = "PRIORITY"
|
||||
FindingOrderFieldReferenceId FindingOrderField = "REFERENCE_ID"
|
||||
FindingOrderFieldKind FindingOrderField = "KIND"
|
||||
)
|
||||
|
||||
func (p FindingOrderField) Column() string {
|
||||
|
||||
@@ -100,7 +100,6 @@ WHERE
|
||||
return err
|
||||
}
|
||||
|
||||
|
||||
func (rp RiskDocument) DeleteByDocumentIDs(
|
||||
ctx context.Context,
|
||||
conn pg.Conn,
|
||||
|
||||
@@ -138,7 +138,7 @@ func (s *FindingService) Create(
|
||||
Kind: req.Kind,
|
||||
Description: req.Description,
|
||||
Source: req.Source,
|
||||
IdentifiedOn: req.IdentifiedOn,
|
||||
IdentifiedOn: req.IdentifiedOn,
|
||||
RootCause: req.RootCause,
|
||||
CorrectiveAction: req.CorrectiveAction,
|
||||
OwnerID: req.OwnerID,
|
||||
|
||||
@@ -20,8 +20,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
organizationCondition = policy.Equals("principal.organization_id", "resource.organization_id")
|
||||
documentWriteActiveOnly = policy.Deny(
|
||||
organizationCondition = policy.Equals("principal.organization_id", "resource.organization_id")
|
||||
documentWriteActiveOnly = policy.Deny(
|
||||
ActionDocumentUpdate,
|
||||
ActionDocumentArchive,
|
||||
ActionDocumentDraftVersionCreate,
|
||||
|
||||
@@ -51,13 +51,13 @@ import (
|
||||
"go.probo.inc/probo/pkg/crypto/keys"
|
||||
"go.probo.inc/probo/pkg/crypto/passwdhash"
|
||||
"go.probo.inc/probo/pkg/esign"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/filemanager"
|
||||
"go.probo.inc/probo/pkg/html2pdf"
|
||||
"go.probo.inc/probo/pkg/iam"
|
||||
"go.probo.inc/probo/pkg/mailer"
|
||||
"go.probo.inc/probo/pkg/mailman"
|
||||
"go.probo.inc/probo/pkg/probo"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/securecookie"
|
||||
"go.probo.inc/probo/pkg/server"
|
||||
"go.probo.inc/probo/pkg/slack"
|
||||
|
||||
@@ -27,10 +27,10 @@ import (
|
||||
"go.probo.inc/probo/pkg/baseurl"
|
||||
"go.probo.inc/probo/pkg/connector"
|
||||
"go.probo.inc/probo/pkg/esign"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/iam"
|
||||
"go.probo.inc/probo/pkg/mailman"
|
||||
"go.probo.inc/probo/pkg/probo"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/securecookie"
|
||||
connect_v1 "go.probo.inc/probo/pkg/server/api/connect/v1"
|
||||
console_v1 "go.probo.inc/probo/pkg/server/api/console/v1"
|
||||
|
||||
@@ -76,7 +76,7 @@ func NewFinding(f *coredata.Finding) *Finding {
|
||||
ReferenceID: f.ReferenceID,
|
||||
Description: f.Description,
|
||||
Source: f.Source,
|
||||
IdentifiedOn: f.IdentifiedOn,
|
||||
IdentifiedOn: f.IdentifiedOn,
|
||||
RootCause: f.RootCause,
|
||||
CorrectiveAction: f.CorrectiveAction,
|
||||
DueDate: f.DueDate,
|
||||
|
||||
@@ -22,8 +22,8 @@ import (
|
||||
"github.com/go-chi/chi/v5"
|
||||
"go.gearno.de/kit/log"
|
||||
"go.probo.inc/probo/pkg/coredata"
|
||||
"go.probo.inc/probo/pkg/gid"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/gid"
|
||||
)
|
||||
|
||||
const presignedURLExpiry = 1 * time.Hour
|
||||
|
||||
@@ -28,7 +28,7 @@ func NewFinding(f *coredata.Finding) *Finding {
|
||||
ReferenceID: f.ReferenceID,
|
||||
Description: f.Description,
|
||||
Source: f.Source,
|
||||
IdentifiedOn: f.IdentifiedOn,
|
||||
IdentifiedOn: f.IdentifiedOn,
|
||||
RootCause: f.RootCause,
|
||||
CorrectiveAction: f.CorrectiveAction,
|
||||
OwnerID: f.OwnerID,
|
||||
|
||||
@@ -22,13 +22,14 @@ import (
|
||||
"github.com/go-chi/chi/v5"
|
||||
"go.gearno.de/kit/httpserver"
|
||||
"go.gearno.de/kit/log"
|
||||
"go.gearno.de/x/ref"
|
||||
"go.probo.inc/probo/pkg/baseurl"
|
||||
"go.probo.inc/probo/pkg/connector"
|
||||
"go.probo.inc/probo/pkg/esign"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/iam"
|
||||
"go.probo.inc/probo/pkg/mailman"
|
||||
"go.probo.inc/probo/pkg/probo"
|
||||
"go.probo.inc/probo/pkg/file"
|
||||
"go.probo.inc/probo/pkg/securecookie"
|
||||
"go.probo.inc/probo/pkg/server/api"
|
||||
"go.probo.inc/probo/pkg/server/api/compliancepage"
|
||||
@@ -37,7 +38,6 @@ import (
|
||||
console_web "go.probo.inc/probo/pkg/server/web"
|
||||
"go.probo.inc/probo/pkg/slack"
|
||||
"go.probo.inc/probo/pkg/trust"
|
||||
"go.gearno.de/x/ref"
|
||||
)
|
||||
|
||||
type Config struct {
|
||||
|
||||
Reference in New Issue
Block a user