forked from x/icebergs
opt some
This commit is contained in:
parent
9a36e8fcc1
commit
56b8c16d4c
@ -121,9 +121,9 @@ func _serve_handle(key string, cmd *ice.Command, m *ice.Message, w http.Response
|
||||
}
|
||||
func _serve_domain(m *ice.Message) string {
|
||||
return kit.GetValid(
|
||||
func() string { return ice.Info.Domain },
|
||||
func() string { return m.R.Header.Get("X-Host") },
|
||||
func() string { return kit.Select("", m.R.Header.Get(Referer), m.R.Method == http.MethodPost) },
|
||||
func() string { return m.R.Header.Get("X-Host") },
|
||||
func() string { return ice.Info.Domain },
|
||||
func() string { return kit.Format("%s://%s", kit.Select("https", ice.HTTP, m.R.TLS == nil), m.R.Host) },
|
||||
)
|
||||
}
|
||||
|
@ -21,6 +21,8 @@ func _action_exec(m *ice.Message, river, storm, index string, arg ...string) {
|
||||
}).Length() == 0, ice.ErrNotRight, index, arg) {
|
||||
return
|
||||
}
|
||||
m.Debug("what %v", m.Option(ice.MSG_USERWEB))
|
||||
m.Debug("what %v", m.Option(ice.MSG_USERPOD))
|
||||
if !ctx.PodCmd(m, index, arg) {
|
||||
m.Cmdy(index, arg)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user