Browse Source

Update SimpleMathsCaptchaGenerator.cs

pull/18430/head
Salih 3 years ago
parent
commit
5472a3b080
  1. 4
      modules/cms-kit/src/Volo.CmsKit.Public.Web/Security/Captcha/SimpleMathsCaptchaGenerator.cs

4
modules/cms-kit/src/Volo.CmsKit.Public.Web/Security/Captcha/SimpleMathsCaptchaGenerator.cs

@ -101,10 +101,10 @@ public class SimpleMathsCaptchaGenerator : ITransientDependency
private byte[] GenerateInternal(string stringText, CaptchaOptions options)
{
var random = new Random();
var fontName = MagickNET.FontNames.First();
var family = MagickNET.FontFamilies.First();
var drawables = new Drawables()
.Font(fontName, options.FontStyle, FontWeight.Normal, FontStretch.Normal)
.Font(family, options.FontStyle, FontWeight.Normal, FontStretch.Normal)
.FontPointSize(options.FontSize)
.StrokeColor(MagickColors.Transparent);

Loading…
Cancel
Save