func (m *GormUserRepository) Delete(ctx context.Context, id uuid.UUID) error {
	defer goa.MeasureSince([]string{"goa", "db", "user", "delete"}, time.Now())

	obj := User{ID: id}

	err := m.db.Delete(&obj).Error

	if err != nil {
		log.Error(ctx, map[string]interface{}{
			"user_id": id,
			"err":     err,
		}, "unable to delete the user")
		return errors.WithStack(err)
	}

	log.Debug(ctx, map[string]interface{}{
		"user_id": id,
	}, "User deleted!")

	return nil
}
// Delete removes a single record.
Delete removes a single record.
// Delete removes a single record .
func (m *GormUserRepository) Delete(ctx context.Context, id uuid.UUID) error {
	defer goa.MeasureSince([]string{"goa", "db", "user", "delete"}, time.Now())
	obj := User{ID: id}
	err := m.db.Delete(&obj).Error
	if err != nil {
		log.Error(ctx, map[string]interface{}{
			"user_id": id,
			"err":     err,
		}, "unable to delete the user")
		return errors.WithStack(err)
	}
	log.Debug(ctx, map[string]interface{}{
		"user_id": id,
	}, "User deleted!")
	return nil
}
func ( m * GormUserRepository ) Delete ( ctx context . Context , id uuid . UUID ) error { defer goa . MeasureSince ( [ ] string { " " , " " , " " , " " } , time . Now ( ) ) obj := User { ID : id } err := m . db . Delete ( & obj ) . Error if err != nil { log . Error ( ctx , map [ string ] interface { } { " " : id , " " : err , } , " " ) return errors . WithStack ( err ) } log . Debug ( ctx , map [ string ] interface { } { " " : id , } , " " ) return nil }
Delete removes a single record.
Delete removes a single record .