Skip to content

Commit

Permalink
馃摝 updates MDK for v0.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
k33g committed Jun 3, 2023
1 parent ffeedd1 commit fe1f09b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ tasks:
env:
#TAG: "v0.0.1"
#TAG: "v0.0.2"
TAG: "v0.0.3" # next release
TAG: "v0.0.3" # current release
#TAG: "v0.0.4" # current release
cmds:
- echo "馃摝 Generating release..."
- git add .
Expand Down
5 changes: 4 additions & 1 deletion handle.http.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package capsule

import (
"encoding/base64"
"strconv"

"github.com/valyala/fastjson"
Expand Down Expand Up @@ -53,7 +54,9 @@ func callHandleHTTP(JSONDataPos *uint32, JSONDataSize uint32) uint64 {
if len(retValue.TextBody) == 0 {
textBody = ""
} else {
textBody = retValue.TextBody
// avoid special characters in jsonString
textBody = base64.StdEncoding.EncodeToString([]byte(retValue.TextBody))
//textBody = retValue.TextBody
}

jsonHTTPResponse := `{"JSONBody":`+jsonBody+`,"TextBody":"`+textBody+`","Headers":`+retValue.Headers+`,"StatusCode":`+strconv.Itoa(retValue.StatusCode)+`}`
Expand Down

0 comments on commit fe1f09b

Please sign in to comment.