Use byte slice instead of arrays
This commit is contained in:
parent
23b9d15a57
commit
5a2a950b1f
2 changed files with 20 additions and 7 deletions
|
|
@ -34,7 +34,7 @@ func (t Theme) GetExercice(id int) (Exercice, error) {
|
|||
}
|
||||
|
||||
func (t Theme) GetExercices() ([]Exercice, error) {
|
||||
if rows, err := DBQuery("SELECT id_exercice, title, statement, hint, depend, gain, video_uri FROM teams WHERE id_theme = ?", t.Id); err != nil {
|
||||
if rows, err := DBQuery("SELECT id_exercice, title, statement, hint, depend, gain, video_uri FROM exercices WHERE id_theme = ?", t.Id); err != nil {
|
||||
return nil, err
|
||||
} else {
|
||||
defer rows.Close()
|
||||
|
|
|
|||
Reference in a new issue