mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-08-10 04:48:43 +00:00
Small fixes - permission + har writing exception (#17)
This commit is contained in:
parent
2c5cd39cec
commit
96a6ac3251
@ -18,7 +18,7 @@ import (
|
||||
)
|
||||
|
||||
func StartReadingFiles(workingDir string) {
|
||||
err := os.MkdirAll(workingDir, 777)
|
||||
err := os.MkdirAll(workingDir, os.ModePerm)
|
||||
utils.CheckErr(err)
|
||||
|
||||
for true {
|
||||
|
@ -39,6 +39,10 @@ type HarFile struct {
|
||||
}
|
||||
|
||||
func (f *HarFile) WriteEntry(request *http.Request, requestTime time.Time, response *http.Response, responseTime time.Time) {
|
||||
// TODO: quick fix until TRA-3212 is implemented
|
||||
if request.URL == nil || request.Method == "" {
|
||||
return
|
||||
}
|
||||
harRequest, err := har.NewRequest(request, true)
|
||||
if err != nil {
|
||||
SilentError("convert-request-to-har", "Failed converting request to HAR %s (%v,%+v)\n", err, err, err)
|
||||
|
Loading…
Reference in New Issue
Block a user