Restore accidentally removed platform mailer by ID func

Needed by the mailer resource
This commit is contained in:
Eli Ribble 2026-05-16 18:12:01 +00:00
parent feff03428f
commit 1c8b13b31e
No known key found for this signature in database
3 changed files with 7 additions and 2 deletions

View file

@ -46,7 +46,9 @@ func mailerBaseQuery() postgres.SelectStatement {
),
)
}
func MailerFromPublicID(ctx context.Context, txn db.Ex, org_id int64, id int64) (*types.Mailer, error) {
// func MailerFromPublicID(ctx context.Context, txn db.Ex, org_id int64, id int64) (*types.Mailer, error) {
func MailerFromID(ctx context.Context, txn db.Ex, org_id int64, id int64) (*types.Mailer, error) {
statement := mailerBaseQuery().WHERE(
table.ComplianceReportRequest.ID.EQ(postgres.Int(id)).AND(
table.Site.OrganizationID.EQ(postgres.Int(org_id))),