Remove per-session value of fnd.Public.
(sess *Session)
| 3847 | |
| 3848 | // Remove per-session value of fnd.Public. |
| 3849 | func (t *Topic) fndRemovePublic(sess *Session) { |
| 3850 | if t.public == nil { |
| 3851 | return |
| 3852 | } |
| 3853 | // FIXME: case of a multiplexing session won't work correctly. |
| 3854 | // Maybe handle it at the proxy topic. |
| 3855 | if pubmap, ok := t.public.(map[string]any); ok { |
| 3856 | delete(pubmap, sess.sid) |
| 3857 | return |
| 3858 | } |
| 3859 | panic("Invalid Fnd.Public type") |
| 3860 | } |
| 3861 | |
| 3862 | func (t *Topic) accessFor(authLvl auth.Level) types.AccessMode { |
| 3863 | return selectAccessMode(authLvl, t.accessAnon, t.accessAuth, getDefaultAccess(t.cat, true, false)) |