Fix profile switch on up and android comments

This commit is contained in:
Theodor S. Midtlien
2026-06-08 14:50:26 +02:00
parent 3bb44e72db
commit f92bc2d325
2 changed files with 7 additions and 7 deletions
+4 -4
View File
@@ -53,10 +53,10 @@ func (p *ProfileArray) Get(i int) *Profile {
├── state.json ← Default profile state ├── state.json ← Default profile state
├── active_profile.json ← Active profile tracker (JSON with Name + Username) ├── active_profile.json ← Active profile tracker (JSON with Name + Username)
└── profiles/ ← Subdirectory for non-default profiles └── profiles/ ← Subdirectory for non-default profiles
├── work.json ← Work profile config ├── work.json ← Legacy work profile config
├── work.state.json ← Work profile state ├── work.state.json ← Legacy work profile state
├── personal.json ← Personal profile config ├── 4c5f5c8198c3989cffb5b5394f5a7ae0.json ← ID profile config
└── personal.state.json ← Personal profile state ├── 4c5f5c8198c3989cffb5b5394f5a7ae0.state.json ← ID profile state
*/ */
// ProfileManager manages profiles for Android // ProfileManager manages profiles for Android
+3 -3
View File
@@ -288,8 +288,8 @@ func doDaemonUp(ctx context.Context, cmd *cobra.Command, client proto.DaemonServ
return fmt.Errorf("setup login request: %v", err) return fmt.Errorf("setup login request: %v", err)
} }
handle := activeProf.ID.String() profileID := activeProf.ID.String()
loginRequest.ProfileName = &handle loginRequest.ProfileName = &profileID
loginRequest.Username = &username loginRequest.Username = &username
profileState, err := pm.GetProfileState(activeProf.ID) profileState, err := pm.GetProfileState(activeProf.ID)
@@ -329,7 +329,7 @@ func doDaemonUp(ctx context.Context, cmd *cobra.Command, client proto.DaemonServ
} }
if _, err := client.Up(ctx, &proto.UpRequest{ if _, err := client.Up(ctx, &proto.UpRequest{
ProfileName: &profileName, ProfileName: &profileID,
Username: &username, Username: &username,
}); err != nil { }); err != nil {
return fmt.Errorf("call service up method: %v", err) return fmt.Errorf("call service up method: %v", err)