Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Commit 53bac89

Browse files
committed
Fix clone/creation/publish flow when the user is logged out
1 parent 0cd7005 commit 53bac89

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/GitHub.App/Controllers/UIController.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,14 @@ public void Start([AllowNull] IConnection connection)
236236
.IsLoggedIn(hosts)
237237
.Do(loggedin =>
238238
{
239+
if (!loggedin && currentFlow != UIControllerFlow.Authentication)
240+
{
241+
connectionManager.Connections.CollectionChanged += (s, e) => {
242+
if (e.Action == System.Collections.Specialized.NotifyCollectionChangedAction.Add)
243+
uiProvider.AddService(typeof(IConnection), e.NewItems[0]);
244+
};
245+
}
246+
239247
machine.Configure(UIViewType.None)
240248
.Permit(Trigger.Auth, UIViewType.Login)
241249
.PermitIf(Trigger.Create, UIViewType.Create, () => loggedin)

0 commit comments

Comments
 (0)