mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-25 22:36:59 -04:00
Show User Agent in System->Tasks for externally triggered commands (#1047)
* Show User Agent in System->Tasks for externally triggered commands (cherry picked from commit fe8f319f7bfdadb7218b6313ada6cae1d2a35ad8) * Fix ESLint (cherry picked from commit c3837c9f7b50534e3eafe1d9fbaf360fee4588b7) * fixup Co-authored-by: Taloth Saldono <Taloth@users.noreply.github.com> Co-authored-by: Mark McDowall <mark@mcdowall.ca>
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace NzbDrone.Common.Http
|
||||
{
|
||||
public static class UserAgentParser
|
||||
{
|
||||
public static string SimplifyUserAgent(string userAgent)
|
||||
{
|
||||
if (userAgent == null || userAgent.StartsWith("Mozilla/5.0"))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return userAgent;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user