mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 10:36:54 -07:00
Use the Application URL if we have it to fix #2201
This commit is contained in:
parent
ac597af702
commit
647a01ebb0
1 changed files with 2 additions and 15 deletions
|
@ -57,21 +57,8 @@ namespace Ombi.Core.Authentication
|
|||
|
||||
public async Task<Uri> GetOAuthUrl(int pinId, string code, string websiteAddress = null)
|
||||
{
|
||||
Uri url;
|
||||
if (websiteAddress.IsNullOrEmpty())
|
||||
{
|
||||
var settings = await _customizationSettingsService.GetSettingsAsync();
|
||||
if (settings.ApplicationUrl.IsNullOrEmpty())
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
url = _api.GetOAuthUrl(pinId, code, settings.ApplicationUrl, false);
|
||||
}
|
||||
else
|
||||
{
|
||||
url = _api.GetOAuthUrl(pinId, code, websiteAddress, false);
|
||||
}
|
||||
var settings = await _customizationSettingsService.GetSettingsAsync();
|
||||
var url = _api.GetOAuthUrl(pinId, code, settings.ApplicationUrl.IsNullOrEmpty() ? websiteAddress : settings.ApplicationUrl, false);
|
||||
|
||||
return url;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue