Remove custom table names as ent uses sensible defaults
The only consequence is renaming option to choice
This commit is contained in:
@@ -34,9 +34,3 @@ func (Answer) Edges() []ent.Edge {
|
||||
Required(),
|
||||
}
|
||||
}
|
||||
|
||||
func (Answer) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "answers",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -35,9 +35,3 @@ func (AskedQuestion) Edges() []ent.Edge {
|
||||
Required(),
|
||||
}
|
||||
}
|
||||
|
||||
func (AskedQuestion) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "asked_questions",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,9 +32,3 @@ func (Choice) Edges() []ent.Edge {
|
||||
edge.To("answers", Answer.Type),
|
||||
}
|
||||
}
|
||||
|
||||
func (Choice) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "options",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,9 +27,3 @@ func (Game) Edges() []ent.Edge {
|
||||
edge.To("questions", Question.Type),
|
||||
}
|
||||
}
|
||||
|
||||
func (Game) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "games",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,9 +37,3 @@ func (Player) Edges() []ent.Edge {
|
||||
edge.To("answers", Answer.Type),
|
||||
}
|
||||
}
|
||||
|
||||
func (Player) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "players",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,9 +37,3 @@ func (Question) Edges() []ent.Edge {
|
||||
edge.To("asked", AskedQuestion.Type),
|
||||
}
|
||||
}
|
||||
|
||||
func (Question) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "questions",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,9 +34,3 @@ func (Session) Edges() []ent.Edge {
|
||||
edge.To("askedQuestions", AskedQuestion.Type),
|
||||
}
|
||||
}
|
||||
|
||||
func (Session) Config() ent.Config {
|
||||
return ent.Config{
|
||||
Table: "sessions",
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user