1.5.0正式版

This commit is contained in:
天爱有情
2024-07-15 13:42:31 +08:00
parent 00ffd1910c
commit df81c15fc7
3 changed files with 10 additions and 4 deletions
@@ -59,7 +59,9 @@ public class CacheImageCaptchaGenerator implements ImageCaptchaGenerator {
this.size = size;
this.waitTime = waitTime;
this.period = period;
this.expireTime = expireTime;
if (expireTime != null){
this.expireTime = expireTime;
}
}
/**
@@ -12,8 +12,10 @@ public class TACBuilderTest {
ImageCaptchaApplication application = TACBuilder.builder()
.addDefaultTemplate()
.addResource("SLIDER", new Resource("classpath", "META-INF/cut-image/resource/1.jpg"))
.addResource("WORD_IMAGE_CLICK", new Resource("classpath", "META-INF/cut-image/resource/1.jpg"))
.addResource("ROTATE", new Resource("classpath", "META-INF/cut-image/resource/1.jpg"))
.build();
CaptchaResponse<ImageCaptchaVO> response = application.generateCaptcha("SLIDER");
CaptchaResponse<ImageCaptchaVO> response = application.generateCaptcha("ROTATE");
System.out.println(response);
}