Skip to content

Commit

Permalink
Fix Browser-error in web-app
Browse files Browse the repository at this point in the history
In the web-app, we don't open another browser-window which needs to be closed at the end. This results in an error in the browser-log: "No active window to close" if the CapacitorBrowser is used => need the DefaultBrowser for it.
  • Loading branch information
flgubler-ergon authored Jan 28, 2025
1 parent 1c2bfa2 commit 1da06b2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion demos/angular-capacitor/src/app/core/core.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ import { HttpClient } from '@angular/common/http';
},
{
provide: Browser,
useClass: CapacitorBrowser
useFactory: (platform: Platform): Browser => platform.is("hybrid") ? new CapacitorBrowser() : new DefaultBrowser(),
deps: [Platform]
},
{
provide: AuthService,
Expand Down

0 comments on commit 1da06b2

Please sign in to comment.