We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9fee9a7 commit 96a23a5Copy full SHA for 96a23a5
internal/leetcode/question_data.go
@@ -2,7 +2,6 @@ package leetcode
2
3
import (
4
"bytes"
5
- "encoding/json"
6
"fmt"
7
"path"
8
"regexp"
@@ -117,9 +116,7 @@ func (question questionType) getTopicTags() []byte {
117
116
118
func (question questionType) getSimilarQuestion() []byte {
119
var sq []similarQuestionType
120
- if question.SimilarQuestions != "" {
121
- json.Unmarshal([]byte(question.SimilarQuestions), &sq)
122
- }
+ jsonDecode([]byte(question.SimilarQuestions), &sq)
123
var buf bytes.Buffer
124
if len(sq) > 0 {
125
buf.WriteString("\n### Similar Questions\n")
0 commit comments