mirror of
https://github.com/sosedoff/pgweb.git
synced 2024-12-14 19:21:46 +03:00
Merge pull request #479 from simhnna/patch-1
Do not show other databases if session is locked
This commit is contained in:
commit
3d14d42356
@ -285,6 +285,10 @@ func ExplainQuery(c *gin.Context) {
|
||||
|
||||
// GetDatabases renders a list of all databases on the server
|
||||
func GetDatabases(c *gin.Context) {
|
||||
if command.Opts.LockSession {
|
||||
serveResult(c, []string{}, nil)
|
||||
return
|
||||
}
|
||||
conn := DB(c)
|
||||
if conn.External {
|
||||
errorResponse(c, 403, errNotPermitted)
|
||||
|
Loading…
Reference in New Issue
Block a user