Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update custom data #106

Merged
merged 3 commits into from
Jul 1, 2024
Merged

Update custom data #106

merged 3 commits into from
Jul 1, 2024

Conversation

erikdubbelboer
Copy link
Member

@erikdubbelboer erikdubbelboer commented Jun 19, 2024

No description provided.

@erikdubbelboer erikdubbelboer changed the base branch from main to leader-election-only June 21, 2024 09:37
@erikdubbelboer erikdubbelboer marked this pull request as ready for review June 24, 2024 20:38
internal/signaling/peer.go Outdated Show resolved Hide resolved
@@ -153,7 +153,7 @@ func (s *PostgresStore) Publish(ctx context.Context, topic string, data []byte)
return nil
}

func (s *PostgresStore) CreateLobby(ctx context.Context, game, lobbyCode, peerID string, public bool, customData map[string]any) error {
func (s *PostgresStore) CreateLobby(ctx context.Context, game, lobbyCode, peerID string, public bool, customData map[string]any, canUpdateBy string) error {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like this argument list is getting quite long. Is it time for a struct?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'll do this when implementing password/maxplayer editing.

Base automatically changed from leader-election-only to main June 25, 2024 13:33
Add new canUpdateBy to lobby to indicate which peers can update the
lobby data.
Co-authored-by: Koen Bollen <[email protected]>
Co-authored-by: Koen Bollen <[email protected]>
@erikdubbelboer erikdubbelboer merged commit 8dfca0a into main Jul 1, 2024
1 check passed
@erikdubbelboer erikdubbelboer deleted the update-custom-data branch July 1, 2024 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants