diff --git a/base/web/serve.go b/base/web/serve.go index 8a5b6457..5ca748ff 100644 --- a/base/web/serve.go +++ b/base/web/serve.go @@ -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) }, ) } diff --git a/core/chat/action.go b/core/chat/action.go index 00f3335e..310e8e98 100644 --- a/core/chat/action.go +++ b/core/chat/action.go @@ -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) }