mirror of
https://github.com/PretendoNetwork/wiiu-chat-secure.git
synced 2026-04-29 02:27:01 -05:00
21 lines
319 B
Go
21 lines
319 B
Go
package database
|
|
|
|
import (
|
|
"context"
|
|
|
|
"go.mongodb.org/mongo-driver/bson"
|
|
)
|
|
|
|
func NewCall(caller uint32, target uint32) {
|
|
document := bson.D{
|
|
{"caller_pid", caller},
|
|
{"target_pid", target},
|
|
{"ringing", true},
|
|
}
|
|
|
|
_, err := callsCollection.InsertOne(context.TODO(), document)
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
}
|