database

package
v0.0.0-...-3b6dc87 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var COLLECTION_NAME = "gameState"

Functions

func DBinstance

func DBinstance() *mongo.Client

func GetGameState

func GetGameState(gameCode string) (string, error)

func UpsertGameState

func UpsertGameState(gameCode string, state string) error

Types

type GameState

type GameState struct {
	BsonID   primitive.ObjectID `bson:"_id"`
	GameCode *string            `json:"gameCode"`
	State    *string            `json:"state"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL