5
0
mirror of https://github.com/wailsapp/wails.git synced 2025-05-03 20:59:30 +08:00

Guard against nil url messages

This commit is contained in:
Lea Anthony 2021-03-06 15:51:06 +11:00
parent 0599a47bfe
commit f9b79d24f8
No known key found for this signature in database
GPG Key ID: 33DAF7BB90A58405

View File

@ -68,6 +68,10 @@ func (u *URL) Start() error {
u.wg.Done()
return
case urlMessage := <-u.urlChannel:
// Guard against nil messages
if urlMessage == nil {
continue
}
messageType := strings.TrimPrefix(urlMessage.Topic(), "url:")
switch messageType {
case "handler":