Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
9b68911d
Commit
9b68911d
authored
Nov 20, 2014
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Made it it compile again
parent
41fb2b4c
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
7 deletions
+3
-7
grafana
+1
-1
pkg/middleware/middleware.go
+1
-2
pkg/routes/api/api_render.go
+1
-1
pkg/setting/setting.go
+0
-3
No files found.
grafana
@
2423f470
Subproject commit
526e232c097eb45c484c9d1387813ff4f05d4a14
Subproject commit
2423f470ef62145c26e74511121eac01e554c363
pkg/middleware/middleware.go
View file @
9b68911d
...
...
@@ -2,7 +2,6 @@ package middleware
import
(
"encoding/json"
"io/ioutil"
"strconv"
"github.com/Unknwon/macaron"
...
...
@@ -81,7 +80,7 @@ func (ctx *Context) JsonApiErr(status int, message string, err error) {
}
func
(
ctx
*
Context
)
JsonBody
(
model
interface
{})
bool
{
b
,
_
:=
ioutil
.
ReadAll
(
ctx
.
Req
.
Body
)
b
,
_
:=
ctx
.
Req
.
Body
()
.
Bytes
(
)
err
:=
json
.
Unmarshal
(
b
,
&
model
)
return
err
==
nil
}
pkg/routes/api/api_render.go
View file @
9b68911d
...
...
@@ -28,5 +28,5 @@ func RenderToPng(c *middleware.Context) {
}
c
.
Resp
.
Header
()
.
Set
(
"Content-Type"
,
"image/png"
)
http
.
ServeFile
(
c
.
Resp
,
c
.
Req
,
pngPath
)
http
.
ServeFile
(
c
.
Resp
,
c
.
Req
.
Request
,
pngPath
)
}
pkg/setting/setting.go
View file @
9b68911d
...
...
@@ -163,9 +163,6 @@ func initSessionService() {
SessionConfig
.
EnableSetCookie
=
Cfg
.
MustBool
(
"session"
,
"enable_set_cookie"
,
true
)
SessionConfig
.
Gclifetime
=
Cfg
.
MustInt64
(
"session"
,
"gc_interval_time"
,
86400
)
SessionConfig
.
Maxlifetime
=
Cfg
.
MustInt64
(
"session"
,
"session_life_time"
,
86400
)
SessionConfig
.
SessionIDHashFunc
=
Cfg
.
MustValueRange
(
"session"
,
"session_id_hashfunc"
,
"sha1"
,
[]
string
{
"sha1"
,
"sha256"
,
"md5"
})
SessionConfig
.
SessionIDHashKey
=
Cfg
.
MustValue
(
"session"
,
"session_id_hashkey"
,
string
(
com
.
RandomCreateBytes
(
16
)))
if
SessionProvider
==
"file"
{
os
.
MkdirAll
(
path
.
Dir
(
SessionConfig
.
ProviderConfig
),
os
.
ModePerm
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment