Go generics and changes in v1.18 (#5)

* ArrayIn to use generics.

* interface{} -> any.
This commit is contained in:
Miroslav Šedivý 2022-07-28 12:20:20 +02:00 committed by GitHub
parent c725e96c90
commit babddacbf3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
26 changed files with 100 additions and 110 deletions

View file

@ -36,7 +36,7 @@ func (peer *WebSocketPeerCtx) setSessionID(sessionId string) {
peer.logger = peer.logger.With().Str("session_id", sessionId).Logger()
}
func (peer *WebSocketPeerCtx) Send(event string, payload interface{}) {
func (peer *WebSocketPeerCtx) Send(event string, payload any) {
peer.mu.Lock()
defer peer.mu.Unlock()