diff --git a/Sieve/Services/SieveProcessor.cs b/Sieve/Services/SieveProcessor.cs index e5eeffb..d0a013d 100644 --- a/Sieve/Services/SieveProcessor.cs +++ b/Sieve/Services/SieveProcessor.cs @@ -187,9 +187,16 @@ namespace Sieve.Services } catch (Exception ex) { - if (ex is SieveException) - throw; - throw new SieveException(ex.Message, ex); + if (_options.Value.ThrowExceptions) + { + if (ex is SieveException) + throw; + throw new SieveException(ex.Message, ex); + } + else + { + return result; + } } } @@ -237,9 +244,16 @@ namespace Sieve.Services } catch (Exception ex) { - if (ex is SieveException) - throw; - throw new SieveException(ex.Message, ex); + if (_options.Value.ThrowExceptions) + { + if (ex is SieveException) + throw; + throw new SieveException(ex.Message, ex); + } + else + { + return result; + } } } @@ -270,9 +284,16 @@ namespace Sieve.Services } catch (Exception ex) { - if (ex is SieveException) - throw; - throw new SieveException(ex.Message, ex); + if (_options.Value.ThrowExceptions) + { + if (ex is SieveException) + throw; + throw new SieveException(ex.Message, ex); + } + else + { + return result; + } } } diff --git a/Sieve/Sieve.nuspec b/Sieve/Sieve.nuspec index 99fb397..69d9738 100644 --- a/Sieve/Sieve.nuspec +++ b/Sieve/Sieve.nuspec @@ -2,7 +2,7 @@ Sieve - 1.3.91 + 1.3.92 Sieve Biarity Biarity @@ -13,7 +13,7 @@ Sieve is a simple, clean, and extensible framework for .NET Core that adds sorting, filtering, and pagination functionality out of the box. Most common use case would be for serving ASP.NET Core GET queries. Documentation available on GitHub: https://github.com/Biarity/Sieve/ - Custom method case-insensitivity, new custom exceptions + Base exception type, max pages feature Copyright 2018 aspnetcore filter sort page paginate sieve search