forgejo/models
limiting-factor d4de6a4e5c fix: UserTypeRemoteUser is an eligible organization member (#11326)
A [safeguard][0] was added to ensure a team member is not an organization. A [discussion][1] concluded that remote users should not yet be allowed to be team members, at least until it is implemented (by F3 or ActivityPub).

As [gof3 v3.11.25][2] has support for [teams][3], remote users need to be added as an eligible team member, otherwise compliance tests for the Forgejo internal driver [implementation][4] fail.

The IsUserByID function is renamed to IsAnEligibleTeamMemberByID to clarify its purpose. The TestIsUserConsistency is removed because the IsUser function is used in [an entirely different context][5] and there is no reason to ensure both are consistent. A unit test is added for IsAnEligibleTeamMemberByID as a replacement and also verifies organizations are not considered eligible.

[0]: https://codeberg.org/forgejo/forgejo/pulls/9757
[1]: https://codeberg.org/forgejo/forgejo/pulls/9757#issuecomment-7802255
[2]: https://code.forgejo.org/f3/gof3/releases/tag/v3.11.25
[3]: https://code.forgejo.org/f3/gof3/pulls/484/files
[4]: 9c565a9b37 (diff-241521b6ebc5a1da660421daea23da1dd1086158)
[5]: b66a76686d/routers/api/v1/api.go (L299-L308)

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/11326
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
Co-authored-by: limiting-factor <limiting-factor@posteo.com>
Co-committed-by: limiting-factor <limiting-factor@posteo.com>
2026-02-17 02:39:46 +01:00
..
actions feat: implement ephemeral runners (#9962) 2026-02-16 18:56:56 +01:00
activities chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
admin feat: cache derived keys for faster keying (#10114) 2025-11-16 14:29:14 +01:00
asymkey chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00
auth refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
avatars feat(perf): remove unused size url parameter for local avatars (#10932) 2026-01-20 04:59:15 +01:00
db feat(activitypub): use structure @PreferredUsername@host.tld:port for actors (#9254) 2026-01-30 23:45:11 +01:00
dbfs fix: garbage collect lingering actions logs (#10009) 2025-11-18 18:59:01 +01:00
fixtures fix: honor org/user project in new issue (#9906) 2026-02-16 05:52:47 +01:00
forgefed log instrumentation & test package (#10371) 2025-12-09 15:37:50 +01:00
forgejo/semver chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
forgejo_migrations feat: implement ephemeral runners (#9962) 2026-02-16 18:56:56 +01:00
forgejo_migrations_legacy fix: normalize secrets consistently, display accurate help (#11052) 2026-02-09 17:02:18 +01:00
git refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
gitea_migrations chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00
issues refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
moderation feat: render a link to poster profile next to the ID within shadow copy details (#10194) 2025-12-09 15:19:10 +01:00
organization fix: UserTypeRemoteUser is an eligible organization member (#11326) 2026-02-17 02:39:46 +01:00
packages refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
perm chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
project fix: honor org/user project in new issue (#9906) 2026-02-16 05:52:47 +01:00
pull fix: do not ignore automerge while a PR is checking for conflicts (#8189) 2025-06-17 10:58:07 +02:00
quota chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
repo refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
secret fix: normalize secrets consistently, display accurate help (#11052) 2026-02-09 17:02:18 +01:00
shared/types chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
system chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
unit chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00
unittest fix NewMockWebServer(): Headers never reached the http client (#11007) 2026-01-24 04:51:18 +01:00
user fix: UserTypeRemoteUser is an eligible organization member (#11326) 2026-02-17 02:39:46 +01:00
webhook refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
error.go fix: don't allow credentials in migrate/push mirror URL 2025-08-30 08:07:23 +02:00
main_test.go chore: move all test blank imports in a single package (#10662) 2026-01-02 05:32:32 +01:00
org.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
org_team.go chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00
org_team_test.go Update module github.com/golangci/golangci-lint/cmd/golangci-lint to v2 (forgejo) (#7367) 2025-03-28 22:22:21 +00:00
org_test.go Update module github.com/golangci/golangci-lint/cmd/golangci-lint to v2 (forgejo) (#7367) 2025-03-28 22:22:21 +00:00
repo.go fix: possible cause of invalid issue counts; cache invalidation occurs before a active transaction is committed (#10130) 2025-11-17 01:07:29 +01:00
repo_test.go Update module github.com/golangci/golangci-lint/cmd/golangci-lint to v2 (forgejo) (#7367) 2025-03-28 22:22:21 +00:00
repo_transfer.go chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00
repo_transfer_test.go chore: fix typos throughout the codebase (#10753) 2026-01-26 22:57:33 +01:00