Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
beego
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
beego
Commits
52075341
Commit
52075341
authored
Sep 08, 2017
by
astaxie
Committed by
GitHub
Sep 08, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2846 from hikenote/master
return template build error rather than log error
parents
c6cef853
4bc4f77c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
sess_redis.go
session/redis/sess_redis.go
+7
-4
template.go
template.go
+1
-0
No files found.
session/redis/sess_redis.go
View file @
52075341
...
...
@@ -160,10 +160,13 @@ func (rp *Provider) SessionInit(maxlifetime int64, savePath string) error {
return
nil
,
err
}
}
_
,
err
=
c
.
Do
(
"SELECT"
,
rp
.
dbNum
)
if
err
!=
nil
{
c
.
Close
()
return
nil
,
err
//some redis proxy such as twemproxy is not support select command
if
rp
.
dbNum
>
0
{
_
,
err
=
c
.
Do
(
"SELECT"
,
rp
.
dbNum
)
if
err
!=
nil
{
c
.
Close
()
return
nil
,
err
}
}
return
c
,
err
},
rp
.
poolsize
)
...
...
template.go
View file @
52075341
...
...
@@ -218,6 +218,7 @@ func BuildTemplate(dir string, files ...string) error {
}
if
err
!=
nil
{
logs
.
Error
(
"parse template err:"
,
file
,
err
)
return
err
}
else
{
beeTemplates
[
file
]
=
t
}
...
...
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