mirror of
https://github.com/fergalmoran/Readarr.git
synced 2025-12-22 09:29:59 +00:00
Binders full of women are no longer ignored
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -17,8 +17,9 @@ Thumbs.db
|
||||
*.cache
|
||||
*.ilk
|
||||
*.log
|
||||
[Bb]in*/
|
||||
[Bb]in
|
||||
[Dd]ebug*/
|
||||
[Rrelease]*/
|
||||
*.lib
|
||||
*.sbr
|
||||
*.nzb
|
||||
|
||||
20
NzbDrone.Web/Helpers/Binders/QualityTypesBinder.cs
Normal file
20
NzbDrone.Web/Helpers/Binders/QualityTypesBinder.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using NzbDrone.Core.Repository.Quality;
|
||||
|
||||
namespace NzbDrone.Web.Helpers.Binders
|
||||
{
|
||||
public class QualityTypesBinder : IModelBinder
|
||||
{
|
||||
public object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext)
|
||||
{
|
||||
var value = bindingContext.ValueProvider.GetValue("quality");
|
||||
var quality = QualityTypes.FindById(Convert.ToInt32(value.AttemptedValue));
|
||||
|
||||
return quality;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user