diff --git a/backend/internal/handler/tenant_handler_test.go b/backend/internal/handler/tenant_handler_test.go index 54285177..80e89d73 100644 --- a/backend/internal/handler/tenant_handler_test.go +++ b/backend/internal/handler/tenant_handler_test.go @@ -85,24 +85,31 @@ func (m *MockUserRepoForHandler) Delete(ctx context.Context, id string) error func (m *MockUserRepoForHandler) FindByEmail(ctx context.Context, email string) (*domain.User, error) { return nil, nil } + func (m *MockUserRepoForHandler) FindByID(ctx context.Context, id string) (*domain.User, error) { return nil, nil } + func (m *MockUserRepoForHandler) FindByIDs(ctx context.Context, ids []string) ([]domain.User, error) { return nil, nil } + func (m *MockUserRepoForHandler) ListByTenant(ctx context.Context, tenantID string) ([]domain.User, error) { return nil, nil } + func (m *MockUserRepoForHandler) List(ctx context.Context, offset, limit int, search string, companyCode string) ([]domain.User, int64, error) { return nil, 0, nil } + func (m *MockUserRepoForHandler) CountByTenant(ctx context.Context, tenantID string) (int64, error) { return 0, nil } + func (m *MockUserRepoForHandler) CountByTenantIDs(ctx context.Context, tenantIDs []string) (map[string]int64, error) { return nil, nil } + func (m *MockUserRepoForHandler) CountByCompanyCodes(ctx context.Context, codes []string) (map[string]int64, error) { args := m.Called(ctx, codes) if args.Get(0) == nil { diff --git a/backend/internal/repository/user_repository.go b/backend/internal/repository/user_repository.go index b793aa6f..eb17527c 100644 --- a/backend/internal/repository/user_repository.go +++ b/backend/internal/repository/user_repository.go @@ -143,7 +143,6 @@ func (r *userRepository) CountByCompanyCodes(ctx context.Context, codes []string Where("company_code IN ? OR tenant_id IN (SELECT id FROM tenants WHERE slug IN ?)", codes, codes). Group("company_code, tenant_id"). Scan(&results).Error - if err != nil { return nil, err }