Skip to content

Commit

Permalink
fix ecmsacript decode error
Browse files Browse the repository at this point in the history
  • Loading branch information
outersky committed Oct 26, 2017
1 parent 7a4fae3 commit 43931c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions harx.go
Expand Up @@ -82,13 +82,13 @@ func (e *HEntry) dumpDirectly(dir string) {
func decode(str string, fileName string) {
data, err := base64.StdEncoding.DecodeString(str)
if err != nil {
log.Fatal(err)
log.Fatal(err," fileName:", fileName)
} else {
ioutil.WriteFile(fileName, data, os.ModePerm)
}
}

var textContentPattern = regexp.MustCompile("text|json|javascript|xml")
var textContentPattern = regexp.MustCompile("text|json|javascript|ecmascript|xml")

func (c *HContent) writeTo(desiredFileName string) {
f := getNoDuplicatePath(desiredFileName)
Expand Down

0 comments on commit 43931c5

Please sign in to comment.