Skip to content

Commit

Permalink
Fixes open-link when user is unauthorized
Browse files Browse the repository at this point in the history
  • Loading branch information
crsib committed Feb 19, 2024
1 parent 0892c6c commit 8e2e1d6
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions modules/mod-cloud-audiocom/CloudProjectUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,17 @@ void OpenProjectFromCloud(
{
ASSERT_MAIN_THREAD();

auto authResult = PerformBlockingAuth(potentialTarget);

if (authResult.Result != AuthResult::Status::Authorised)
{
LinkFailedDialog dialog { potentialTarget != nullptr ?
&ProjectWindow::Get(*potentialTarget) :
nullptr };
dialog.ShowModal();
return;
}

auto progressDialog = MakeProgress();

auto future = CloudSyncService::Get().OpenFromCloud(
Expand Down

0 comments on commit 8e2e1d6

Please sign in to comment.