mirror of https://github.com/synctv-org/synctv
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
320 B
Go
10 lines
320 B
Go
1 year ago
|
package db
|
||
|
|
||
|
import "github.com/synctv-org/synctv/internal/model"
|
||
|
|
||
|
func GetRoomUserRelation(roomID, userID uint) (*model.RoomUserRelation, error) {
|
||
|
roomUserRelation := &model.RoomUserRelation{}
|
||
|
err := db.Where("room_id = ? AND user_id = ?", roomID, userID).First(roomUserRelation).Error
|
||
|
return roomUserRelation, err
|
||
|
}
|