aboutsummaryrefslogtreecommitdiffstats
path: root/modules/markup
diff options
context:
space:
mode:
Diffstat (limited to 'modules/markup')
-rw-r--r--modules/markup/external/external.go8
-rw-r--r--modules/markup/markup.go2
-rw-r--r--modules/markup/orgmode/orgmode.go2
3 files changed, 6 insertions, 6 deletions
diff --git a/modules/markup/external/external.go b/modules/markup/external/external.go
index 5963a06d30..02cf61be16 100644
--- a/modules/markup/external/external.go
+++ b/modules/markup/external/external.go
@@ -67,7 +67,7 @@ func (p *Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]stri
// write to temp file
f, err := ioutil.TempFile("", "gitea_input")
if err != nil {
- log.Error(4, "%s create temp file when rendering %s failed: %v", p.Name(), p.Command, err)
+ log.Error("%s create temp file when rendering %s failed: %v", p.Name(), p.Command, err)
return []byte("")
}
defer os.Remove(f.Name())
@@ -75,13 +75,13 @@ func (p *Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]stri
_, err = io.Copy(f, rd)
if err != nil {
f.Close()
- log.Error(4, "%s write data to temp file when rendering %s failed: %v", p.Name(), p.Command, err)
+ log.Error("%s write data to temp file when rendering %s failed: %v", p.Name(), p.Command, err)
return []byte("")
}
err = f.Close()
if err != nil {
- log.Error(4, "%s close temp file when rendering %s failed: %v", p.Name(), p.Command, err)
+ log.Error("%s close temp file when rendering %s failed: %v", p.Name(), p.Command, err)
return []byte("")
}
args = append(args, f.Name())
@@ -98,7 +98,7 @@ func (p *Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]stri
}
cmd.Stdout = buf
if err := cmd.Run(); err != nil {
- log.Error(4, "%s render run command %s %v failed: %v", p.Name(), commands[0], args, err)
+ log.Error("%s render run command %s %v failed: %v", p.Name(), commands[0], args, err)
return []byte("")
}
return buf.Bytes()
diff --git a/modules/markup/markup.go b/modules/markup/markup.go
index c506007723..0ea4099600 100644
--- a/modules/markup/markup.go
+++ b/modules/markup/markup.go
@@ -74,7 +74,7 @@ func render(parser Parser, rawBytes []byte, urlPrefix string, metas map[string]s
// TODO: one day the error should be returned.
result, err := PostProcess(result, urlPrefix, metas, isWiki)
if err != nil {
- log.Error(3, "PostProcess: %v", err)
+ log.Error("PostProcess: %v", err)
}
return SanitizeBytes(result)
}
diff --git a/modules/markup/orgmode/orgmode.go b/modules/markup/orgmode/orgmode.go
index 6b6d622d7b..f63155201e 100644
--- a/modules/markup/orgmode/orgmode.go
+++ b/modules/markup/orgmode/orgmode.go
@@ -35,7 +35,7 @@ func (Parser) Extensions() []string {
func Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) (result []byte) {
defer func() {
if err := recover(); err != nil {
- log.Error(4, "Panic in orgmode.Render: %v Just returning the rawBytes", err)
+ log.Error("Panic in orgmode.Render: %v Just returning the rawBytes", err)
result = rawBytes
}
}()