func (s Store) Find(ctx context.Context, id int) (*entity.AuditLog, error) {
	var log entity.AuditLog
	err := s.db.GetContext(ctx, &log, "SELECT * FROM auditlogs WHERE id = ? LIMIT 1", id)
	return &log, errors.WithStack(checkNotFound(err))
}
Find finds the entity by id.
package audit
import (
	"context"
	"database/sql"
	"go-webapp-example/internal/pkg/entity"
	"go-webapp-example/pkg/clock"
	"go-webapp-example/pkg/db"
	sq "github.com/Masterminds/squirrel"
	"github.com/pkg/errors"
	"gopkg.in/guregu/null.v3"
)
type Store struct {
	db    *db.Connection
	clock *clock.Clock
}
func NewStore(conn *db.Connection, opts ...func(s *Store)) *Store {
	s := &Store{db: conn}
	for _, opt := range opts {
		opt(s)
	}
	return s
}