private async Task selectWorkspace(SelectableWorkspaceViewModel workspace)
        {
            await interactorFactory.SetDefaultWorkspace(workspace.WorkspaceId).Execute();

            accessRestrictionStorage.SetNoDefaultWorkspaceStateReached(false);
            Close();
        }
 private IObservable <Unit> selectWorkspace(SelectableWorkspaceViewModel workspace)
 => Observable.DeferAsync(async _ =>
 {
     await interactorFactory.SetDefaultWorkspace(workspace.WorkspaceId).Execute();
     accessRestrictionStorage.SetNoDefaultWorkspaceStateReached(false);
     await navigationService.Close(this, Unit.Default);
     return(Observable.Return(Unit.Default));
 });
예제 #3
0
        public bool TryHandleNoDefaultWorkspaceError(Exception error)
        {
            if (error is NoDefaultWorkspaceException)
            {
                accessRestrictionStorage.SetNoDefaultWorkspaceStateReached(true);
                return(true);
            }

            return(false);
        }