print question solutions if set
parent
e81de97e8b
commit
e1ca7dd70b
7
main.go
7
main.go
|
|
@ -130,6 +130,13 @@ func ReviewQ(db DB, user IDU, q IDQ) (string, string, error) {
|
|||
if len(question.Clues) == 0 || response == "/clue" {
|
||||
response = readline()
|
||||
}
|
||||
if len(question.Solution) > 0 {
|
||||
fmt.Printf("> Solution:")
|
||||
for i := range question.Solution {
|
||||
fmt.Printf("\n\t%s", question.Solution[i].ToString(db.UserResolution(user)))
|
||||
}
|
||||
fmt.Println()
|
||||
}
|
||||
if id, _ := db.LastAnswer(user, q); id == "" {
|
||||
} else if lastAnswer := db.Answer(id); lastAnswer.A != "" {
|
||||
fmt.Printf("> Last time, you responded:\n\t%s\n", lastAnswer.A)
|
||||
|
|
|
|||
Loading…
Reference in New Issue