You've already forked Sonarr
							
							
				mirror of
				https://github.com/Sonarr/Sonarr.git
				synced 2025-10-31 00:07:55 +02:00 
			
		
		
		
	Fixed: Release group will not contain file extension
This commit is contained in:
		| @@ -16,13 +16,11 @@ namespace NzbDrone.Api.Authentication | |||||||
|         private readonly IConfigFileProvider _configFileProvider; |         private readonly IConfigFileProvider _configFileProvider; | ||||||
|         private static readonly NzbDroneUser AnonymousUser = new NzbDroneUser { UserName = "Anonymous" }; |         private static readonly NzbDroneUser AnonymousUser = new NzbDroneUser { UserName = "Anonymous" }; | ||||||
| 
 | 
 | ||||||
| 
 |  | ||||||
|         public AuthenticationService(IConfigFileProvider configFileProvider) |         public AuthenticationService(IConfigFileProvider configFileProvider) | ||||||
|         { |         { | ||||||
|             _configFileProvider = configFileProvider; |             _configFileProvider = configFileProvider; | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
| 
 |  | ||||||
|         public IUserIdentity Validate(string username, string password) |         public IUserIdentity Validate(string username, string password) | ||||||
|         { |         { | ||||||
|             if (!Enabled) |             if (!Enabled) | ||||||
|   | |||||||
| @@ -474,5 +474,13 @@ namespace NzbDrone.Core.Test.ParserTests | |||||||
|         { |         { | ||||||
|             Parser.Parser.ParseReleaseGroup(title).Should().Be(expected); |             Parser.Parser.ParseReleaseGroup(title).Should().Be(expected); | ||||||
|         } |         } | ||||||
|  | 
 | ||||||
|  |         [Test] | ||||||
|  |         public void should_not_include_extension_in_releaseGroup() | ||||||
|  |         { | ||||||
|  |             const string path = @"C:\Test\Doctor.Who.2005.s01e01.internal.bdrip.x264-archivist.mkv"; | ||||||
|  | 
 | ||||||
|  |             Parser.Parser.ParsePath(path).ReleaseGroup.Should().Be("archivist"); | ||||||
|  |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -129,8 +129,11 @@ namespace NzbDrone.Core.Parser | |||||||
|             if (result == null) |             if (result == null) | ||||||
|             { |             { | ||||||
|                 Logger.Warn("Unable to parse episode info from path {0}", path); |                 Logger.Warn("Unable to parse episode info from path {0}", path); | ||||||
|  |                 return null; | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|  |             result.ReleaseGroup = ParseReleaseGroup(fileInfo.Name.Replace(fileInfo.Extension, "")); | ||||||
|  | 
 | ||||||
|             return result; |             return result; | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user