summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyren223 <kyren223@proton.me>2025-08-05 16:03:58 +0300
committerKyren223 <kyren223@proton.me>2025-08-05 16:03:58 +0300
commit274dee5b25ed249492faeea1c0a4e33aa26cb60c (patch)
treecc5230c35897320c891a81d3b42f794db9bffcc1
parent3fee3e4218406373e4c5d51a5b1a3e9ab9301e4d (diff)
Fixed loading screen after accepting TOS not spinning the spinner
-rw-r--r--internal/client/ui/core/core.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/internal/client/ui/core/core.go b/internal/client/ui/core/core.go
index bf76c00..3ccc67f 100644
--- a/internal/client/ui/core/core.go
+++ b/internal/client/ui/core/core.go
@@ -180,11 +180,11 @@ func (m Model) View() string {
return m.tos.View()
case ConnectedAcceptedTos:
- // TODO: auth
+ // TODO(kyren): auth
return m.loading.View()
case Authenticated:
- // Continue
+ // NOTE(kyren): Continue
default:
panic(fmt.Sprintf("unexpected core.State: %#v", m.state))
@@ -303,8 +303,10 @@ func (m Model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
case ConnectedReceivedTos:
fallthrough
case ConnectedAcceptedTos:
+ var lcmd tea.Cmd
+ m.loading, lcmd = m.loading.Update(msg)
cmd := m.updateConnected(msg)
- return m, cmd
+ return m, tea.Batch(cmd, lcmd)
case Authenticated:
cmd := m.updateAuthenticated(msg)